xdgmimeglob: Fix a memory leak on a duplicate-entry path
Rather than strdup()
ing strings when passing them into
_xdg_glob_list_append()
, strdup()
them inside the function
instead.
This avoids a leak in the case that the list entry (tuple of data
and
mime_type
) already exists in the list.
Signed-off-by: Philip Withnall pwithnall@gnome.org
Merge request reports
Activity
assigned to @pwithnall
- Resolved by Philip Withnall
Too bad the CI is broken again.
added 4 commits
-
842dfc93...40515663 - 3 commits from branch
xdg:master
- be1f98d4 - xdgmimeglob: Fix a memory leak on a duplicate-entry path
-
842dfc93...40515663 - 3 commits from branch
Merging as it has two approvals and is a straightforward fix. Thanks for the reviews!
If you have 5 minutes to take a look at !38 (merged) too, that would be grand.