Skip to content

xdgmime: fix double free

Michael Catanzaro requested to merge mcatanzaro/xdgmime-corruption into main

We free xdg_dirs[i] twice, but fail to free xdg_dirs itself.

Also, since free() is NULL-safe, there is no need for the second check here.

Discovered in: https://gitlab.freedesktop.org/xdg/xdgmime/-/merge_requests/16#note_1432025

Merge request reports