mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-02-05 01:50:27 +01:00
Merge branch 'master' into 'master'
Fix a memory leak See merge request cairo/cairo!568
This commit is contained in:
commit
409a6b5229
1 changed files with 3 additions and 1 deletions
|
|
@ -2831,8 +2831,10 @@ _cairo_pdf_interchange_set_custom_metadata (cairo_pdf_surface_t *surface,
|
|||
if (value && strlen(value)) {
|
||||
new_data.name = strdup (name);
|
||||
status = _cairo_utf8_to_pdf_string (value, &s);
|
||||
if (unlikely (status))
|
||||
if (unlikely (status)) {
|
||||
free (new_data.name);
|
||||
return status;
|
||||
}
|
||||
new_data.value = s;
|
||||
status = _cairo_array_append (&ic->custom_metadata, &new_data);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue