aboutsummaryrefslogtreecommitdiff
path: root/src/fs/gnunet-publish.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-10-11 14:50:07 +0000
committerChristian Grothoff <christian@grothoff.org>2013-10-11 14:50:07 +0000
commitcd67a970afe36e8a2aa99e48cbe103cc4cc26424 (patch)
tree67e5023676f2278485e35a2b71ce246b9933f406 /src/fs/gnunet-publish.c
parent3dd666cbad61490c0de1cb891fd1b36c8536c348 (diff)
downloadgnunet-cd67a970afe36e8a2aa99e48cbe103cc4cc26424.tar.gz
gnunet-cd67a970afe36e8a2aa99e48cbe103cc4cc26424.zip
generate progress events when publishing directories (towards fixing #2230)
Diffstat (limited to 'src/fs/gnunet-publish.c')
-rw-r--r--src/fs/gnunet-publish.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/fs/gnunet-publish.c b/src/fs/gnunet-publish.c
index 7f7423ae5..12d9a6084 100644
--- a/src/fs/gnunet-publish.c
+++ b/src/fs/gnunet-publish.c
@@ -227,12 +227,25 @@ progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info)
227 { 227 {
228 s = GNUNET_STRINGS_relative_time_to_string (info->value.publish.eta, 228 s = GNUNET_STRINGS_relative_time_to_string (info->value.publish.eta,
229 GNUNET_YES); 229 GNUNET_YES);
230 FPRINTF (stdout, _("Publishing `%s' at %llu/%llu (%s remaining)\n"), 230 FPRINTF (stdout,
231 _("Publishing `%s' at %llu/%llu (%s remaining)\n"),
231 info->value.publish.filename, 232 info->value.publish.filename,
232 (unsigned long long) info->value.publish.completed, 233 (unsigned long long) info->value.publish.completed,
233 (unsigned long long) info->value.publish.size, s); 234 (unsigned long long) info->value.publish.size, s);
234 } 235 }
235 break; 236 break;
237 case GNUNET_FS_STATUS_PUBLISH_PROGRESS_DIRECTORY:
238 if (verbose)
239 {
240 s = GNUNET_STRINGS_relative_time_to_string (info->value.publish.specifics.progress_directory.eta,
241 GNUNET_YES);
242 FPRINTF (stdout,
243 _("Publishing `%s' at %llu/%llu (%s remaining)\n"),
244 info->value.publish.filename,
245 (unsigned long long) info->value.publish.specifics.progress_directory.completed,
246 (unsigned long long) info->value.publish.specifics.progress_directory.total, s);
247 }
248 break;
236 case GNUNET_FS_STATUS_PUBLISH_ERROR: 249 case GNUNET_FS_STATUS_PUBLISH_ERROR:
237 FPRINTF (stderr, _("Error publishing: %s.\n"), 250 FPRINTF (stderr, _("Error publishing: %s.\n"),
238 info->value.publish.specifics.error.message); 251 info->value.publish.specifics.error.message);