projects
/
geeqie.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Fix crash when loading collection listing inexistent files.
[geeqie.git]
/
src
/
collect.c
diff --git
a/src/collect.c
b/src/collect.c
index
c69155d
..
e3c0157
100644
(file)
--- a/
src/collect.c
+++ b/
src/collect.c
@@
-595,6
+595,10
@@
gboolean collection_add_check(CollectionData *cd, FileData *fd, gboolean sorted,
struct stat st;
gboolean valid;
+ if (!fd) return FALSE;
+
+ g_assert(fd->magick == FD_MAGICK);
+
if (must_exist)
{
valid = (stat_utf8(fd->path, &st) && !S_ISDIR(st.st_mode));