wayland-cursor: Plug leak of filename on load_all_cursors_from_dir()

This commit is contained in:
Ander Conselvan de Oliveira 2012-06-19 13:45:39 +03:00 committed by Kristian Høgsberg
parent 61260854ec
commit 2261007953

View file

@ -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);