diff options
author | Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> | 2012-06-19 13:45:39 +0300 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2012-06-19 11:36:31 -0400 |
commit | 226100795309569cc0f101ed6524afc6ac3a9584 (patch) | |
tree | 78b9179a8de901516c31c2af27bc7893e97dea22 /cursor | |
parent | 61260854ec92a43e4e0f5cf1469eecbe404eac5a (diff) |
wayland-cursor: Plug leak of filename on load_all_cursors_from_dir()
Diffstat (limited to 'cursor')
-rw-r--r-- | cursor/xcursor.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/cursor/xcursor.c b/cursor/xcursor.c index 360f7f3..0fe0440 100644 --- a/cursor/xcursor.c +++ b/cursor/xcursor.c @@ -883,8 +883,10 @@ load_all_cursors_from_dir(const char *path, int size, continue; f = fopen(full, "r"); - if (!f) + if (!f) { + free(full); continue; + } images = XcursorFileLoadImages(f, size); @@ -894,6 +896,7 @@ load_all_cursors_from_dir(const char *path, int size, } fclose (f); + free(full); } closedir(dir); |