GNUnet  0.10.x
Functions
gnunet-service-fs_indexing.h File Reference

indexing for the file-sharing service More...

#include "gnunet_block_lib.h"
#include "gnunet_core_service.h"
#include "gnunet_datastore_service.h"
#include "gnunet_peer_lib.h"
#include "gnunet_protocols.h"
#include "gnunet_signatures.h"
#include "gnunet_util_lib.h"
Include dependency graph for gnunet-service-fs_indexing.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int GNUNET_FS_handle_on_demand_block (const struct GNUNET_HashCode *key, uint32_t size, const void *data, enum GNUNET_BLOCK_Type type, uint32_t priority, uint32_t anonymity, uint32_t replication, struct GNUNET_TIME_Absolute expiration, uint64_t uid, GNUNET_DATASTORE_DatumProcessor cont, void *cont_cls)
 We've received an on-demand encoded block from the datastore. More...
 
void GNUNET_FS_indexing_send_list (struct GNUNET_MQ_Handle *mq)
 Transmit information about indexed files to mq. More...
 
int GNUNET_FS_indexing_do_unindex (const struct GNUNET_HashCode *fid)
 Remove a file from the index. More...
 
void GNUNET_FS_add_to_index (const char *filename, const struct GNUNET_HashCode *file_id)
 Add the given file to the list of indexed files. More...
 
int GNUNET_FS_indexing_init (const struct GNUNET_CONFIGURATION_Handle *c, struct GNUNET_DATASTORE_Handle *d)
 Initialize the indexing submodule. More...
 
void GNUNET_FS_indexing_done (void)
 Shutdown the module. More...
 

Detailed Description

indexing for the file-sharing service

Author
Christian Grothoff

Definition in file gnunet-service-fs_indexing.h.

Function Documentation

◆ GNUNET_FS_handle_on_demand_block()

int GNUNET_FS_handle_on_demand_block ( const struct GNUNET_HashCode key,
uint32_t  size,
const void *  data,
enum GNUNET_BLOCK_Type  type,
uint32_t  priority,
uint32_t  anonymity,
uint32_t  replication,
struct GNUNET_TIME_Absolute  expiration,
uint64_t  uid,
GNUNET_DATASTORE_DatumProcessor  cont,
void *  cont_cls 
)

We've received an on-demand encoded block from the datastore.

Attempt to do on-demand encoding and (if successful), call the continuation with the resulting block. On error, clean up and ask the datastore for more results.

Parameters
keykey for the content
sizenumber of bytes in data
datacontent stored
typetype of the content
prioritypriority of the content
anonymityanonymity-level for the content
replicationreplication-level for the content
expirationexpiration time for the content
uidunique identifier for the datum; maybe 0 if no unique identifier is available
contfunction to call with the actual block (at most once, on success)
cont_clsclosure for cont
Returns
GNUNET_OK on success

Attempt to do on-demand encoding and (if successful), call the continuation with the resulting block. On error, clean up and ask the datastore for more results.

Parameters
keykey for the content
sizenumber of bytes in data
datacontent stored
typetype of the content
prioritypriority of the content
anonymityanonymity-level for the content
replicationreplication-level for the content
expirationexpiration time for the content
uidunique identifier for the datum; maybe 0 if no unique identifier is available
contfunction to call with the actual block (at most once, on success)
cont_clsclosure for cont
Returns
GNUNET_OK on success

Definition at line 278 of file gnunet-service-fs_indexing.c.

References _, ACCESS, DBLOCK_SIZE, fh, OnDemandBlock::file_id, IndexInfo::filename, fn, gettext_noop, GNUNET_BLOCK_TYPE_FS_DBLOCK, GNUNET_break, GNUNET_CONTAINER_multihashmap_get(), GNUNET_CRYPTO_hash(), GNUNET_CRYPTO_hash_to_aes_key(), GNUNET_CRYPTO_symmetric_encrypt(), GNUNET_DATASTORE_remove(), GNUNET_DISK_file_close(), GNUNET_DISK_file_open(), GNUNET_DISK_file_read(), GNUNET_DISK_file_seek(), GNUNET_DISK_OPEN_READ, GNUNET_DISK_PERM_NONE, GNUNET_DISK_SEEK_SET, GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_ERROR, GNUNET_ERROR_TYPE_WARNING, GNUNET_h2s(), GNUNET_log, GNUNET_ntohll(), GNUNET_OK, GNUNET_STATISTICS_update(), GNUNET_SYSERR, GNUNET_YES, GSF_stats, OnDemandBlock::offset, remove_cont(), and STRERROR.

Referenced by handle_datastore_reply(), process_local_reply(), and process_migration_content().

289 {
290  const struct OnDemandBlock *odb;
291  struct GNUNET_HashCode nkey;
294  struct GNUNET_HashCode query;
295  ssize_t nsize;
296  char ndata[DBLOCK_SIZE];
297  char edata[DBLOCK_SIZE];
298  const char *fn;
299  struct GNUNET_DISK_FileHandle *fh;
300  uint64_t off;
301  struct IndexInfo *ii;
302 
303  if (size != sizeof (struct OnDemandBlock))
304  {
305  GNUNET_break (0);
307  key,
308  size,
309  data,
310  -1,
311  -1,
312  &remove_cont, NULL);
313  return GNUNET_SYSERR;
314  }
315  odb = (const struct OnDemandBlock *) data;
316  off = GNUNET_ntohll (odb->offset);
318  &odb->file_id);
319  if (NULL == ii)
320  {
321  GNUNET_break (0);
323  "Failed to find index %s\n",
324  GNUNET_h2s (&odb->file_id));
325  return GNUNET_SYSERR;
326  }
327  fn = ii->filename;
328  if ((NULL == fn) || (0 != ACCESS (fn, R_OK)))
329  {
331  gettext_noop ("# index blocks removed: original file inaccessible"),
332  1,
333  GNUNET_YES);
335  key,
336  size,
337  data,
338  -1,
339  -1,
340  &remove_cont,
341  NULL);
342  return GNUNET_SYSERR;
343  }
344  if ( (NULL ==
345  (fh =
349  (off != GNUNET_DISK_file_seek (fh,
350  off,
352  (-1 == (nsize = GNUNET_DISK_file_read (fh,
353  ndata,
354  sizeof (ndata)))) )
355  {
357  _("Could not access indexed file `%s' (%s) at offset %llu: %s\n"),
358  GNUNET_h2s (&odb->file_id),
359  fn,
360  (unsigned long long) off,
361  (fn == NULL) ? _("not indexed") : STRERROR (errno));
362  if (fh != NULL)
365  key,
366  size,
367  data,
368  -1,
369  -1,
370  &remove_cont,
371  NULL);
372  return GNUNET_SYSERR;
373  }
375  GNUNET_CRYPTO_hash (ndata,
376  nsize,
377  &nkey);
379  &skey,
380  &iv);
382  nsize,
383  &skey,
384  &iv,
385  edata);
386  GNUNET_CRYPTO_hash (edata,
387  nsize,
388  &query);
389  if (0 != memcmp (&query,
390  key,
391  sizeof (struct GNUNET_HashCode)))
392  {
394  _("Indexed file `%s' changed at offset %llu\n"),
395  fn,
396  (unsigned long long) off);
398  key,
399  size,
400  data,
401  -1,
402  -1,
403  &remove_cont,
404  NULL);
405  return GNUNET_SYSERR;
406  }
408  "On-demand encoded block for query `%s'\n",
409  GNUNET_h2s (key));
410  cont (cont_cls,
411  key,
412  nsize,
413  edata,
415  priority,
416  anonymity,
417  replication,
418  expiration,
419  uid);
420  return GNUNET_OK;
421 }
Open the file for reading.
int GNUNET_DISK_file_close(struct GNUNET_DISK_FileHandle *h)
Close an open file.
Definition: disk.c:1817
static void remove_cont(void *cls, int success, struct GNUNET_TIME_Absolute min_expiration, const char *msg)
Continuation called from datastore's remove function.
ssize_t GNUNET_DISK_file_read(const struct GNUNET_DISK_FileHandle *h, void *result, size_t len)
Read the contents of a binary file into a buffer.
Definition: disk.c:881
static struct GNUNET_CONTAINER_MultiHashMap * ifm
Maps hash over content of indexed files to the respective 'struct IndexInfo'.
#define STRERROR(i)
Definition: plibc.h:676
const char * filename
Name of the indexed file.
static unsigned int replication
Nobody is allowed to do anything to the file.
struct GNUNET_STATISTICS_Handle * GSF_stats
Handle for reporting statistics.
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
const char * GNUNET_h2s(const struct GNUNET_HashCode *hc)
Convert a hash value to a string (for printing debug messages).
off_t GNUNET_DISK_file_seek(const struct GNUNET_DISK_FileHandle *h, off_t offset, enum GNUNET_DISK_Seek whence)
Move the read/write pointer in a file.
Definition: disk.c:241
void GNUNET_STATISTICS_update(struct GNUNET_STATISTICS_Handle *handle, const char *name, int64_t delta, int make_persistent)
Set statistic value for the peer.
#define GNUNET_break(cond)
Use this for internal assertion violations that are not fatal (can be handled) but should not occur...
void * GNUNET_CONTAINER_multihashmap_get(const struct GNUNET_CONTAINER_MultiHashMap *map, const struct GNUNET_HashCode *key)
Given a key find a value in the map matching the key.
#define _(String)
GNU gettext support macro.
Definition: platform.h:208
static char * fn
Filename of the unique file.
void GNUNET_CRYPTO_hash(const void *block, size_t size, struct GNUNET_HashCode *ret)
Compute hash of a given block.
Definition: crypto_hash.c:44
ssize_t GNUNET_CRYPTO_symmetric_encrypt(const void *block, size_t size, const struct GNUNET_CRYPTO_SymmetricSessionKey *sessionkey, const struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, void *result)
Encrypt a block using a symmetric sessionkey.
static int fh
Handle to the unique file.
struct GNUNET_DATASTORE_QueueEntry * GNUNET_DATASTORE_remove(struct GNUNET_DATASTORE_Handle *h, const struct GNUNET_HashCode *key, size_t size, const void *data, unsigned int queue_priority, unsigned int max_queue_size, GNUNET_DATASTORE_ContinuationWithStatus cont, void *cont_cls)
Explicitly remove some content from the database.
A 512-bit hashcode.
In-memory information about indexed files (also available on-disk).
void GNUNET_CRYPTO_hash_to_aes_key(const struct GNUNET_HashCode *hc, struct GNUNET_CRYPTO_SymmetricSessionKey *skey, struct GNUNET_CRYPTO_SymmetricInitializationVector *iv)
Convert a hashcode into a key.
Definition: crypto_hash.c:212
#define DBLOCK_SIZE
Size of the individual blocks used for file-sharing.
Definition: fs.h:40
#define GNUNET_SYSERR
Definition: gnunet_common.h:79
static unsigned int size
Size of the "table".
Definition: peer.c:67
struct GNUNET_HashCode file_id
Hash code of the entire content of the file that was indexed (used to uniquely identify the plaintext...
Definition: block_fs.h:91
Seek an absolute position (from the start of the file).
static struct GNUNET_DATASTORE_Handle * dsh
Datastore handle.
#define GNUNET_log(kind,...)
uint64_t offset
At which offset should we be able to find this on-demand encoded block? (in NBO)
Definition: block_fs.h:97
Data block (leaf) in the CHK tree.
#define GNUNET_YES
Definition: gnunet_common.h:80
static unsigned int anonymity
uint32_t data
The data value.
struct GNUNET_DISK_FileHandle * GNUNET_DISK_file_open(const char *fn, enum GNUNET_DISK_OpenFlags flags, enum GNUNET_DISK_AccessPermissions perm)
Open a file.
Definition: disk.c:1673
#define ACCESS(p, m)
Definition: plibc.h:656
Handle used to access files (and pipes).
uint64_t GNUNET_ntohll(uint64_t n)
Convert unsigned 64-bit integer to host byte order.
Definition: common_endian.c:48
index block (indexing a DBlock that can be obtained directly from reading the plaintext file) ...
Definition: block_fs.h:84
#define gettext_noop(String)
Definition: gettext.h:69
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_FS_indexing_send_list()

void GNUNET_FS_indexing_send_list ( struct GNUNET_MQ_Handle mq)

Transmit information about indexed files to mq.

Parameters
mqmessage queue to send information to

Definition at line 430 of file gnunet-service-fs_indexing.c.

References env, IndexInfo::file_id, IndexInfoMessage::file_id, IndexInfo::filename, fn, GNUNET_break, GNUNET_MAX_MESSAGE_SIZE, GNUNET_memcpy, GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_END, GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_ENTRY, GNUNET_MQ_msg, GNUNET_MQ_msg_extra, GNUNET_MQ_send(), IndexInfo::next, and IndexInfoMessage::reserved.

Referenced by handle_client_index_list_get().

431 {
432  struct GNUNET_MQ_Envelope *env;
433  struct IndexInfoMessage *iim;
434  struct GNUNET_MessageHeader *iem;
435  size_t slen;
436  const char *fn;
437  struct IndexInfo *pos;
438 
439  for (pos = indexed_files_head; NULL != pos; pos = pos->next)
440  {
441  fn = pos->filename;
442  slen = strlen (fn) + 1;
443  if (slen + sizeof (struct IndexInfoMessage) >=
445  {
446  GNUNET_break (0);
447  break;
448  }
449  env = GNUNET_MQ_msg_extra (iim,
450  slen,
452  iim->reserved = 0;
453  iim->file_id = pos->file_id;
454  GNUNET_memcpy (&iim[1],
455  fn,
456  slen);
457  GNUNET_MQ_send (mq,
458  env);
459  }
460  env = GNUNET_MQ_msg (iem,
462  GNUNET_MQ_send (mq,
463  env);
464 }
struct IndexInfo * next
This is a doubly linked list.
struct GNUNET_HashCode file_id
Hash of the contents of the file.
const char * filename
Name of the indexed file.
#define GNUNET_MQ_msg(mvar, type)
Allocate a GNUNET_MQ_Envelope.
Definition: gnunet_mq_lib.h:67
Message send by FS service in response to a request asking for a list of all indexed files...
Definition: fs.h:199
static struct IndexInfo * indexed_files_head
Head of linked list of indexed files.
struct GNUNET_HashCode file_id
Hash of the indexed file.
Definition: fs.h:215
#define GNUNET_break(cond)
Use this for internal assertion violations that are not fatal (can be handled) but should not occur...
#define GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_ENTRY
Reply to client with an indexed file name.
#define GNUNET_MQ_msg_extra(mvar, esize, type)
Allocate an envelope, with extra space allocated after the space needed by the message struct...
Definition: gnunet_mq_lib.h:52
#define GNUNET_memcpy(dst, src, n)
static char * fn
Filename of the unique file.
In-memory information about indexed files (also available on-disk).
struct GNUNET_MQ_Envelope * env
Definition: 005.c:1
#define GNUNET_MAX_MESSAGE_SIZE
Largest supported message (to be precise, one byte more than the largest possible message...
#define GNUNET_MESSAGE_TYPE_FS_INDEX_LIST_END
Reply to client indicating end of list.
Header for all communications.
void GNUNET_MQ_send(struct GNUNET_MQ_Handle *mq, struct GNUNET_MQ_Envelope *ev)
Send a message with the given message queue.
Definition: mq.c:353
uint32_t reserved
Always zero.
Definition: fs.h:210
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_FS_indexing_do_unindex()

int GNUNET_FS_indexing_do_unindex ( const struct GNUNET_HashCode fid)

Remove a file from the index.

Parameters
fididentifier of the file to remove
Returns
GNUNET_YES if the fid was found

Definition at line 474 of file gnunet-service-fs_indexing.c.

References IndexInfo::file_id, GNUNET_break, GNUNET_CONTAINER_DLL_remove, GNUNET_CONTAINER_multihashmap_remove(), GNUNET_free, GNUNET_NO, GNUNET_OK, GNUNET_YES, IndexInfo::next, and write_index_list().

Referenced by handle_client_unindex().

475 {
476  struct IndexInfo *pos;
477 
478  for (pos = indexed_files_head; NULL != pos; pos = pos->next)
479  {
480  if (0 == memcmp (&pos->file_id,
481  fid,
482  sizeof (struct GNUNET_HashCode)))
483  {
486  pos);
489  &pos->file_id,
490  pos));
491  GNUNET_free (pos);
492  write_index_list ();
493  return GNUNET_YES;
494  }
495  }
496  return GNUNET_NO;
497 }
#define GNUNET_CONTAINER_DLL_remove(head, tail, element)
Remove an element from a DLL.
struct IndexInfo * next
This is a doubly linked list.
struct GNUNET_HashCode file_id
Hash of the contents of the file.
static struct GNUNET_CONTAINER_MultiHashMap * ifm
Maps hash over content of indexed files to the respective 'struct IndexInfo'.
#define GNUNET_NO
Definition: gnunet_common.h:81
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
static struct IndexInfo * indexed_files_head
Head of linked list of indexed files.
#define GNUNET_break(cond)
Use this for internal assertion violations that are not fatal (can be handled) but should not occur...
static void write_index_list()
Write the current index information list to disk.
int GNUNET_CONTAINER_multihashmap_remove(struct GNUNET_CONTAINER_MultiHashMap *map, const struct GNUNET_HashCode *key, const void *value)
Remove the given key-value pair from the map.
A 512-bit hashcode.
In-memory information about indexed files (also available on-disk).
#define GNUNET_YES
Definition: gnunet_common.h:80
#define GNUNET_free(ptr)
Wrapper around free.
static struct IndexInfo * indexed_files_tail
Tail of linked list of indexed files.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_FS_add_to_index()

void GNUNET_FS_add_to_index ( const char *  filename,
const struct GNUNET_HashCode file_id 
)

Add the given file to the list of indexed files.

Parameters
filenamename of the file
file_idhash identifier for filename

Definition at line 507 of file gnunet-service-fs_indexing.c.

References _, IndexInfo::file_id, IndexInfo::filename, GNUNET_assert, GNUNET_CONTAINER_DLL_insert, GNUNET_CONTAINER_multihashmap_get(), GNUNET_CONTAINER_multihashmap_put(), GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY, GNUNET_ERROR_TYPE_DEBUG, GNUNET_ERROR_TYPE_INFO, GNUNET_h2s(), GNUNET_log, GNUNET_malloc, GNUNET_memcpy, GNUNET_OK, and write_index_list().

Referenced by signal_index_ok().

509 {
510  struct IndexInfo *ii;
511  size_t slen;
512 
514  file_id);
515  if (NULL != ii)
516  {
518  _("Index request received for file `%s' is already indexed as `%s'. Permitting anyway.\n"),
519  filename,
520  ii->filename);
521  return;
522  }
524  "Adding file %s to index as %s\n",
525  filename,
526  GNUNET_h2s (file_id));
527  slen = strlen (filename) + 1;
528  ii = GNUNET_malloc (sizeof (struct IndexInfo) + slen);
529  ii->file_id = *file_id;
530  ii->filename = (const char *) &ii[1];
531  GNUNET_memcpy (&ii[1],
532  filename,
533  slen);
536  ii);
539  &ii->file_id,
540  ii,
542  write_index_list ();
543 }
struct GNUNET_HashCode file_id
Hash of the contents of the file.
#define GNUNET_CONTAINER_DLL_insert(head, tail, element)
Insert an element at the head of a DLL.
static struct GNUNET_CONTAINER_MultiHashMap * ifm
Maps hash over content of indexed files to the respective 'struct IndexInfo'.
#define GNUNET_assert(cond)
Use this for fatal errors that cannot be handled.
const char * filename
Name of the indexed file.
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
const char * GNUNET_h2s(const struct GNUNET_HashCode *hc)
Convert a hash value to a string (for printing debug messages).
static struct IndexInfo * indexed_files_head
Head of linked list of indexed files.
void * GNUNET_CONTAINER_multihashmap_get(const struct GNUNET_CONTAINER_MultiHashMap *map, const struct GNUNET_HashCode *key)
Given a key find a value in the map matching the key.
#define _(String)
GNU gettext support macro.
Definition: platform.h:208
#define GNUNET_memcpy(dst, src, n)
static void write_index_list()
Write the current index information list to disk.
static char * filename
In-memory information about indexed files (also available on-disk).
There must only be one value per key; storing a value should fail if a value under the same key alrea...
int GNUNET_CONTAINER_multihashmap_put(struct GNUNET_CONTAINER_MultiHashMap *map, const struct GNUNET_HashCode *key, void *value, enum GNUNET_CONTAINER_MultiHashMapOption opt)
Store a key-value pair in the map.
#define GNUNET_log(kind,...)
#define GNUNET_malloc(size)
Wrapper around malloc.
static struct IndexInfo * indexed_files_tail
Tail of linked list of indexed files.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_FS_indexing_init()

int GNUNET_FS_indexing_init ( const struct GNUNET_CONFIGURATION_Handle c,
struct GNUNET_DATASTORE_Handle d 
)

Initialize the indexing submodule.

Parameters
cconfiguration to use
ddatastore to use
Returns
GNUNET_OK on success
Parameters
cconfiguration to use
ddatastore to use

Definition at line 580 of file gnunet-service-fs_indexing.c.

References GNUNET_CONTAINER_multihashmap_create(), GNUNET_OK, GNUNET_YES, and read_index_list().

Referenced by run().

582 {
583  cfg = c;
584  dsh = d;
586  GNUNET_YES);
587  read_index_list ();
588  return GNUNET_OK;
589 }
static struct GNUNET_CONTAINER_MultiHashMap * ifm
Maps hash over content of indexed files to the respective 'struct IndexInfo'.
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
static void read_index_list()
Read index information from disk.
static struct GNUNET_DATASTORE_Handle * dsh
Datastore handle.
struct GNUNET_CONTAINER_MultiHashMap * GNUNET_CONTAINER_multihashmap_create(unsigned int len, int do_not_copy_keys)
Create a multi hash map.
#define GNUNET_YES
Definition: gnunet_common.h:80
static const struct GNUNET_CONFIGURATION_Handle * cfg
Our configuration.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GNUNET_FS_indexing_done()

void GNUNET_FS_indexing_done ( void  )

Shutdown the module.

Definition at line 550 of file gnunet-service-fs_indexing.c.

References IndexInfo::fhc, IndexInfo::file_id, GNUNET_break, GNUNET_CONTAINER_DLL_remove, GNUNET_CONTAINER_multihashmap_destroy(), GNUNET_CONTAINER_multihashmap_remove(), GNUNET_CRYPTO_hash_file_cancel(), GNUNET_free, and GNUNET_OK.

Referenced by shutdown_task().

551 {
552  struct IndexInfo *pos;
553 
554  while (NULL != (pos = indexed_files_head))
555  {
558  pos);
559  if (pos->fhc != NULL)
563  &pos->file_id,
564  pos));
565  GNUNET_free (pos);
566  }
568  ifm = NULL;
569  cfg = NULL;
570 }
#define GNUNET_CONTAINER_DLL_remove(head, tail, element)
Remove an element from a DLL.
struct GNUNET_HashCode file_id
Hash of the contents of the file.
static struct GNUNET_CONTAINER_MultiHashMap * ifm
Maps hash over content of indexed files to the respective 'struct IndexInfo'.
#define GNUNET_OK
Named constants for return values.
Definition: gnunet_common.h:78
static struct IndexInfo * indexed_files_head
Head of linked list of indexed files.
#define GNUNET_break(cond)
Use this for internal assertion violations that are not fatal (can be handled) but should not occur...
void GNUNET_CONTAINER_multihashmap_destroy(struct GNUNET_CONTAINER_MultiHashMap *map)
Destroy a hash map.
int GNUNET_CONTAINER_multihashmap_remove(struct GNUNET_CONTAINER_MultiHashMap *map, const struct GNUNET_HashCode *key, const void *value)
Remove the given key-value pair from the map.
void GNUNET_CRYPTO_hash_file_cancel(struct GNUNET_CRYPTO_FileHashContext *fhc)
Cancel a file hashing operation.
In-memory information about indexed files (also available on-disk).
struct GNUNET_CRYPTO_FileHashContext * fhc
Context for hashing of the file.
static const struct GNUNET_CONFIGURATION_Handle * cfg
Our configuration.
#define GNUNET_free(ptr)
Wrapper around free.
static struct IndexInfo * indexed_files_tail
Tail of linked list of indexed files.
Here is the call graph for this function:
Here is the caller graph for this function: