diff options
author | Christian Grothoff <christian@grothoff.org> | 2015-05-31 19:43:33 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2015-05-31 19:43:33 +0000 |
commit | af64dbfd58f360db789e6ae67e19a2d5cbe66bc1 (patch) | |
tree | 54a3ee542eea51c9381b12745168123952398a30 /src/fs/fs_publish.c | |
parent | e558b1206056e28b40298b171e85115430eb3bf7 (diff) | |
download | gnunet-af64dbfd58f360db789e6ae67e19a2d5cbe66bc1.tar.gz gnunet-af64dbfd58f360db789e6ae67e19a2d5cbe66bc1.zip |
-fix #3799
Diffstat (limited to 'src/fs/fs_publish.c')
-rw-r--r-- | src/fs/fs_publish.c | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/src/fs/fs_publish.c b/src/fs/fs_publish.c index d9c732ee8..f29722fee 100644 --- a/src/fs/fs_publish.c +++ b/src/fs/fs_publish.c | |||
@@ -143,6 +143,8 @@ ds_put_cont (void *cls, | |||
143 | } | 143 | } |
144 | return; | 144 | return; |
145 | } | 145 | } |
146 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
147 | "SOME DONE!\n"); | ||
146 | pc->any_done = GNUNET_YES; | 148 | pc->any_done = GNUNET_YES; |
147 | GNUNET_assert (NULL == pc->upload_task); | 149 | GNUNET_assert (NULL == pc->upload_task); |
148 | pc->upload_task = | 150 | pc->upload_task = |
@@ -196,11 +198,15 @@ signal_publish_error (struct GNUNET_FS_FileInformation *p, | |||
196 | pi.value.publish.eta = GNUNET_TIME_UNIT_FOREVER_REL; | 198 | pi.value.publish.eta = GNUNET_TIME_UNIT_FOREVER_REL; |
197 | pi.value.publish.specifics.error.message = emsg; | 199 | pi.value.publish.specifics.error.message = emsg; |
198 | p->client_info = GNUNET_FS_publish_make_status_ (&pi, pc, p, 0); | 200 | p->client_info = GNUNET_FS_publish_make_status_ (&pi, pc, p, 0); |
199 | if ((p->is_directory != GNUNET_YES) && (p->filename != NULL) && | 201 | if ((p->is_directory != GNUNET_YES) && |
202 | (NULL != p->filename) && | ||
203 | (GNUNET_YES == pc->any_done) && | ||
200 | (p->data.file.do_index == GNUNET_YES)) | 204 | (p->data.file.do_index == GNUNET_YES)) |
201 | { | 205 | { |
202 | /* run unindex to clean up */ | 206 | /* run unindex to clean up */ |
203 | GNUNET_FS_unindex_start (pc->h, p->filename, NULL); | 207 | GNUNET_FS_unindex_start (pc->h, |
208 | p->filename, | ||
209 | NULL); | ||
204 | } | 210 | } |
205 | 211 | ||
206 | } | 212 | } |
@@ -1278,18 +1284,21 @@ GNUNET_FS_publish_signal_suspend_ (void *cls) | |||
1278 | * @param msg error message on error, otherwise NULL | 1284 | * @param msg error message on error, otherwise NULL |
1279 | */ | 1285 | */ |
1280 | static void | 1286 | static void |
1281 | finish_reserve (void *cls, int success, | 1287 | finish_reserve (void *cls, |
1288 | int success, | ||
1282 | struct GNUNET_TIME_Absolute min_expiration, | 1289 | struct GNUNET_TIME_Absolute min_expiration, |
1283 | const char *msg) | 1290 | const char *msg) |
1284 | { | 1291 | { |
1285 | struct GNUNET_FS_PublishContext *pc = cls; | 1292 | struct GNUNET_FS_PublishContext *pc = cls; |
1286 | 1293 | ||
1287 | pc->qre = NULL; | 1294 | pc->qre = NULL; |
1288 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Reservation complete (%d)!\n", success); | 1295 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1296 | "Reservation complete (%d)!\n", | ||
1297 | success); | ||
1289 | if ((msg != NULL) || (success <= 0)) | 1298 | if ((msg != NULL) || (success <= 0)) |
1290 | { | 1299 | { |
1291 | GNUNET_asprintf (&pc->fi->emsg, | 1300 | GNUNET_asprintf (&pc->fi->emsg, |
1292 | _("Insufficient space for publishing: %s"), | 1301 | _("Datastore failure: %s"), |
1293 | msg); | 1302 | msg); |
1294 | signal_publish_error (pc->fi, pc, pc->fi->emsg); | 1303 | signal_publish_error (pc->fi, pc, pc->fi->emsg); |
1295 | return; | 1304 | return; |