projects
/
oweals
/
gnunet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6a30eb2
)
-do not try to desearialize search directories
author
Christian Grothoff
<christian@grothoff.org>
Sat, 18 Feb 2012 21:37:48 +0000
(21:37 +0000)
committer
Christian Grothoff
<christian@grothoff.org>
Sat, 18 Feb 2012 21:37:48 +0000
(21:37 +0000)
src/fs/fs_api.c
patch
|
blob
|
history
diff --git
a/src/fs/fs_api.c
b/src/fs/fs_api.c
index cae2c693dc9acf870066e45c4bdc4dd2b6b0fa6e..b930f35bdd4be431daa73a713191bf01a040248d 100644
(file)
--- a/
src/fs/fs_api.c
+++ b/
src/fs/fs_api.c
@@
-2641,7
+2641,15
@@
deserialize_search_file (void *cls, const char *filename)
char *emsg;
struct GNUNET_BIO_ReadHandle *rh;
struct GNUNET_FS_SearchContext *sc;
+ struct stat buf;
+ if (0 != STAT (filename, &buf))
+ {
+ GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, "stat", filename);
+ return GNUNET_OK;
+ }
+ if (S_ISDIR (buf.st_mode))
+ return GNUNET_OK; /* skip directories */
ser = get_serialization_short_name (filename);
rh = GNUNET_BIO_read_open (filename);
if (rh == NULL)