[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r7330 - GNUnet/src/applications/fs/fsui
From: |
gnunet |
Subject: |
[GNUnet-SVN] r7330 - GNUnet/src/applications/fs/fsui |
Date: |
Thu, 26 Jun 2008 00:48:17 -0600 (MDT) |
Author: grothoff
Date: 2008-06-26 00:48:17 -0600 (Thu, 26 Jun 2008)
New Revision: 7330
Modified:
GNUnet/src/applications/fs/fsui/fsui.c
GNUnet/src/applications/fs/fsui/upload.c
Log:
ffx
Modified: GNUnet/src/applications/fs/fsui/fsui.c
===================================================================
--- GNUnet/src/applications/fs/fsui/fsui.c 2008-06-26 06:31:57 UTC (rev
7329)
+++ GNUnet/src/applications/fs/fsui/fsui.c 2008-06-26 06:48:17 UTC (rev
7330)
@@ -760,7 +760,6 @@
}
/* 1d) stop uploading */
upos = ctx->activeUploads.child;
- suspend_active_upload(upos);
while (upos != NULL)
{
if ((upos->state == GNUNET_FSUI_ACTIVE) ||
@@ -768,8 +767,9 @@
(upos->state == GNUNET_FSUI_ERROR)
|| (upos->state == GNUNET_FSUI_COMPLETED))
{
- /* NOTE: will force transitive termination
- of rest of tree! */
+ if (upos->state == GNUNET_FSUI_ACTIVE)
+ upos->state = GNUNET_FSUI_PENDING;
+ suspend_active_upload(upos->child);
GNUNET_thread_stop_sleep (upos->shared->handle);
GNUNET_thread_join (upos->shared->handle, &unused);
if (upos->state != GNUNET_FSUI_PENDING)
Modified: GNUnet/src/applications/fs/fsui/upload.c
===================================================================
--- GNUnet/src/applications/fs/fsui/upload.c 2008-06-26 06:31:57 UTC (rev
7329)
+++ GNUnet/src/applications/fs/fsui/upload.c 2008-06-26 06:48:17 UTC (rev
7330)
@@ -573,9 +573,15 @@
if (ul->keywords != NULL)
GNUNET_ECRS_uri_destroy (ul->keywords);
if (ul->uri != NULL)
- GNUNET_ECRS_uri_destroy (ul->uri);
+ {
+ GNUNET_ECRS_uri_destroy (ul->uri);
+ ul->uri = NULL;
+ }
if (ul->meta != NULL)
- GNUNET_meta_data_destroy (ul->meta);
+ {
+ GNUNET_meta_data_destroy (ul->meta);
+ ul->meta = NULL;
+ }
/* unlink from parent */
next = ul->parent->child;
if (next == NULL)
@@ -624,17 +630,17 @@
struct GNUNET_FSUI_UploadList *parent = data;
char *filename;
struct GNUNET_FSUI_UploadList *child;
- struct GNUNET_MetaData *md;
+ struct GNUNET_MetaData *md_tmp;
filename = GNUNET_malloc (strlen (dirName) + strlen (name) + 2);
strcpy (filename, dirName);
if (dirName[strlen (dirName) - 1] != DIR_SEPARATOR)
strcat (filename, DIR_SEPARATOR_STR);
strcat (filename, name);
- md = GNUNET_meta_data_create ();
- child = addUploads (parent->shared, filename, NULL, md, parent);
+ md_tmp = GNUNET_meta_data_create ();
+ child = addUploads (parent->shared, filename, NULL, md_tmp, parent);
GNUNET_free (filename);
- GNUNET_meta_data_destroy (md);
+ GNUNET_meta_data_destroy (md_tmp);
if (child == NULL)
return GNUNET_SYSERR;
parent->total += child->total;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r7330 - GNUnet/src/applications/fs/fsui,
gnunet <=