ats_ril: - removed some redundantly saved plugin environment attributes
[oweals/gnunet.git] / src / fs / fs_unindex.c
index bb3accb8239a224fbf90558b71b7c36b71884fba..7e189d69711ac5923b0f0223d473cde84d8bf18f 100644 (file)
@@ -271,15 +271,12 @@ static void
 unindex_finish (struct GNUNET_FS_UnindexContext *uc)
 {
   char *emsg;
-  struct GNUNET_FS_Uri *uri;
   struct UnindexMessage req;
 
   /* generate final progress message */
   unindex_progress (uc, uc->file_size, NULL, 0, 0);
-  GNUNET_FS_tree_encoder_finish (uc->tc, &uri, &emsg);
+  GNUNET_FS_tree_encoder_finish (uc->tc, &emsg);
   uc->tc = NULL;
-  if (uri != NULL)
-    GNUNET_FS_uri_destroy (uri);
   GNUNET_DISK_file_close (uc->fh);
   uc->fh = NULL;
   GNUNET_DATASTORE_disconnect (uc->dsh, GNUNET_NO);
@@ -325,8 +322,8 @@ unindex_finish (struct GNUNET_FS_UnindexContext *uc)
  * @param reason kind of progress we are making
  */
 static void
-unindex_directory_scan_cb (void *cls, 
-                          const char *filename, 
+unindex_directory_scan_cb (void *cls,
+                          const char *filename,
                           int is_directory,
                           enum GNUNET_FS_DirScannerProgressUpdateReason reason)
 {
@@ -384,7 +381,7 @@ GNUNET_FS_unindex_do_extract_keywords_ (struct GNUNET_FS_UnindexContext *uc)
     ex = NULL;
   uc->dscan = GNUNET_FS_directory_scan_start (uc->filename,
                                              GNUNET_NO, ex,
-                                             &unindex_directory_scan_cb, 
+                                             &unindex_directory_scan_cb,
                                              uc);
   GNUNET_free_non_null (ex);
 }
@@ -394,7 +391,7 @@ GNUNET_FS_unindex_do_extract_keywords_ (struct GNUNET_FS_UnindexContext *uc)
  * Continuation called to notify client about result of the remove
  * operation for the UBlock.
  *
- * @param cls the 'struct GNUNET_FS_UnindexContext *' 
+ * @param cls the 'struct GNUNET_FS_UnindexContext *'
  * @param success GNUNET_SYSERR on failure (including timeout/queue drop)
  *                GNUNET_NO if content was already there
  *                GNUNET_YES (or other positive value) on success
@@ -412,10 +409,10 @@ continue_after_remove (void *cls,
   struct GNUNET_FS_UnindexContext *uc = cls;
 
   uc->dqe = NULL;
-  if (success != GNUNET_YES)  
+  if (success != GNUNET_YES)
     GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
                _("Failed to remove UBlock: %s\n"),
-               msg);  
+               msg);
   uc->ksk_offset++;
   GNUNET_FS_unindex_do_remove_kblocks_ (uc);
 }
@@ -467,14 +464,14 @@ process_kblock_for_unindex (void *cls,
   if (0 == uc->first_uid)
   {
     /* remember UID of first result to detect cycles */
-    uc->first_uid = uid;    
+    uc->first_uid = uid;
   }
   else if (uid == uc->first_uid)
   {
     /* no more additional results */
     uc->ksk_offset++;
     GNUNET_FS_unindex_do_remove_kblocks_ (uc);
-    return;  
+    return;
   }
   GNUNET_assert (GNUNET_BLOCK_TYPE_FS_UBLOCK == type);
   if (size < sizeof (struct UBlock))
@@ -492,10 +489,10 @@ process_kblock_for_unindex (void *cls,
     goto get_next;
   }
   {
-    char pt[size - sizeof (struct UBlock)];  
+    char pt[size - sizeof (struct UBlock)];
     struct GNUNET_CRYPTO_EccPublicSignKey anon_pub;
     const char *keyword;
-     
+
     GNUNET_CRYPTO_ecc_key_get_public_for_signature (GNUNET_CRYPTO_ecc_key_get_anonymous (),
                                                    &anon_pub);
     keyword = &uc->ksk_uri->data.ksk.keywords[uc->ksk_offset][1];
@@ -730,7 +727,7 @@ GNUNET_FS_unindex_signal_suspend_ (void *cls)
   }
   if (NULL != uc->tc)
   {
-    GNUNET_FS_tree_encoder_finish (uc->tc, NULL, NULL);
+    GNUNET_FS_tree_encoder_finish (uc->tc, NULL);
     uc->tc = NULL;
   }
   if (uc->fh != NULL)
@@ -760,7 +757,7 @@ GNUNET_FS_unindex_signal_suspend_ (void *cls)
  * @return NULL on error, otherwise handle
  */
 struct GNUNET_FS_UnindexContext *
-GNUNET_FS_unindex_start (struct GNUNET_FS_Handle *h, 
+GNUNET_FS_unindex_start (struct GNUNET_FS_Handle *h,
                         const char *filename,
                          void *cctx)
 {
@@ -831,7 +828,7 @@ GNUNET_FS_unindex_stop (struct GNUNET_FS_UnindexContext *uc)
   }
   if (NULL != uc->tc)
   {
-    GNUNET_FS_tree_encoder_finish (uc->tc, NULL, NULL);
+    GNUNET_FS_tree_encoder_finish (uc->tc, NULL);
     uc->tc = NULL;
   }
   if (uc->fh != NULL)