aboutsummaryrefslogtreecommitdiff
path: root/src/fs/gnunet-publish.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2010-03-12 14:35:37 +0000
committerChristian Grothoff <christian@grothoff.org>2010-03-12 14:35:37 +0000
commitfba12e5552667f6ae8521c9f955fa8279e0165a3 (patch)
tree6e7a6d7845ee82f7598939b6dc392f7bdfb6933a /src/fs/gnunet-publish.c
parenta6f43190ab793b3487da2133735e166e337000c4 (diff)
downloadgnunet-fba12e5552667f6ae8521c9f955fa8279e0165a3.tar.gz
gnunet-fba12e5552667f6ae8521c9f955fa8279e0165a3.zip
init
Diffstat (limited to 'src/fs/gnunet-publish.c')
-rw-r--r--src/fs/gnunet-publish.c29
1 files changed, 17 insertions, 12 deletions
diff --git a/src/fs/gnunet-publish.c b/src/fs/gnunet-publish.c
index db4ea978e..860a81522 100644
--- a/src/fs/gnunet-publish.c
+++ b/src/fs/gnunet-publish.c
@@ -441,19 +441,24 @@ run (void *cls,
441 } 441 }
442 emsg = NULL; 442 emsg = NULL;
443 if (0 != STAT (args[0], &sbuf)) 443 if (0 != STAT (args[0], &sbuf))
444 GNUNET_asprintf (&emsg, 444 {
445 _("Could not access file: %s\n"), 445 GNUNET_asprintf (&emsg,
446 STRERROR (errno)); 446 _("Could not access file: %s\n"),
447 STRERROR (errno));
448 fi = NULL;
449 }
447 else if (S_ISDIR (sbuf.st_mode)) 450 else if (S_ISDIR (sbuf.st_mode))
448 fi = GNUNET_FS_file_information_create_from_directory (NULL, 451 {
449 args[0], 452 fi = GNUNET_FS_file_information_create_from_directory (NULL,
450 &GNUNET_FS_directory_scanner_default, 453 args[0],
451 l, 454 &GNUNET_FS_directory_scanner_default,
452 !do_insert, 455 l,
453 anonymity, 456 !do_insert,
454 priority, 457 anonymity,
455 GNUNET_TIME_relative_to_absolute (DEFAULT_EXPIRATION), 458 priority,
456 &emsg); 459 GNUNET_TIME_relative_to_absolute (DEFAULT_EXPIRATION),
460 &emsg);
461 }
457 else 462 else
458 { 463 {
459 fi = GNUNET_FS_file_information_create_from_file (NULL, 464 fi = GNUNET_FS_file_information_create_from_file (NULL,