* TESTING:
- consider changing API for peer-group termination to
call continuation when done
+
+* HOSTLIST:
+ - 'server' uses 'GNUNET_PEERINFO_iterate', should probably switch to notification API
+ (for more instant / up-to-date hostlists at lower cost) [OPTIMIZATION]
Urgent items (before announcing ng.gnunet.org):
* topology
- - HELLO advertising does not work (no solicitation!)
+ - valgrind crash (in topology test case):
+==31107== Invalid read of size 8
+==31107== at 0x401DA1: free_peer (gnunet-daemon-topology.c:480)
+==31107== by 0x4030A2: cleaning_task (gnunet-daemon-topology.c:1212)
+==31107== by 0x545DCBD: run_ready (scheduler.c:482)
+==31107== by 0x545E0CD: GNUNET_SCHEDULER_run (scheduler.c:609)
+==31107== by 0x545B00F: GNUNET_PROGRAM_run (program.c:223)
+==31107== by 0x403477: main (gnunet-daemon-topology.c:1346)
+==31107== Address 0x737e828 is 8 bytes inside a block of size 144 free'd
+==31107== at 0x4C21DBC: free (vg_replace_malloc.c:325)
+==31107== by 0x544240B: GNUNET_xfree_ (common_allocation.c:144)
+==31107== by 0x401E13: free_peer (gnunet-daemon-topology.c:487)
+==31107== by 0x4030A2: cleaning_task (gnunet-daemon-topology.c:1212)
+==31107== by 0x545DCBD: run_ready (scheduler.c:482)
+==31107== by 0x545E0CD: GNUNET_SCHEDULER_run (scheduler.c:609)
+==31107== by 0x545B00F: GNUNET_PROGRAM_run (program.c:223)
+==31107== by 0x403477: main (gnunet-daemon-topology.c:1346)
+==31107==
- considers peers 'connected' well before they actually are
- (since core notifies about it too early?)
- - needs testing
+ (since core notifies about it too early?);
+ - (forced) disconnect does not work (also CORE API issue)
+ - needs testing (not sure the current testcase does much...)
* hostlist
- test fails (looks like it works, but that's because of a bad
connectivity notification; somehow core is unable to send
libgnunetcore_la_SOURCES = \
core_api.c core.h \
- core_api_peer_get_info.c
+ core_api_peer_get_info.c \
+ core_api_peer_request.c
libgnunetcore_la_LIBADD = \
$(top_builddir)/src/arm/libgnunetarm.la \
$(top_builddir)/src/util/libgnunetutil.la \
* Print a meta data entry.
*
* @param cls closure (unused)
+ * @param plugin_name name of the plugin that generated the meta data
* @param type type of the keyword
* @param format format of data
* @param data_mime_type mime type of data
* metadata and the filename).
*
* @param cls closure
+ * @param plugin_name name of the plugin that generated the meta data
* @param type type of the meta data
* @param format format of data
* @param data_mime_type mime type of data
* Merge metadata entries.
*
* @param cls closure, target metadata structure
+ * @param plugin_name name of the plugin that generated the meta data
* @param type type of the meta data
* @param format format of data
* @param data_mime_type mime type of data
/*
This file is part of GNUnet.
- (C) 2009 Christian Grothoff (and other contributing authors)
+ (C) 2009, 2010 Christian Grothoff (and other contributing authors)
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
void GNUNET_CORE_disconnect (struct GNUNET_CORE_Handle *handle);
+struct GNUNET_CORE_PeerRequestHandle;
+
+struct GNUNET_CORE_PeerRequestHandle *
+struct GNUNET_CORE_peer_request_connect (struct GNUNET_SCHEDULER_Handle *sched,
+ const struct GNUNET_CONFIGURATION_Handle *cfg,
+ const struct GNUNET_PeerIdentity * peer,
+ GNUNET_SCHEDULER_Task cont,
+ void *cont_cls);
+
+
+struct GNUNET_CORE_PeerRequestHandle *
+struct GNUNET_CORE_peer_request_disconnect (struct GNUNET_SCHEDULER_Handle *sched,
+ const struct GNUNET_CONFIGURATION_Handle *cfg,
+ const struct GNUNET_PeerIdentity * peer,
+ GNUNET_SCHEDULER_Task cont,
+ void *cont_cls);
+
+void
+GNUNET_CORE_peer_request_cancel (struct GNUNET_CORE_PeerRequestHandle *req);
+
+
/**
* Function called with statistics about the given peer.
*
* Convert a binary address into a human
* readable address.
*
- * @param handle connection to transport service
+ * @param sched scheduler to use
* @param cfg configuration to use
* @param address address to convert (binary format)
* @param addressLen number of bytes in address
/**
* Try to connect to the specified peer.
*
- * @param peer who we should try to connect to
- * @param pos entry in our friend list; NULL if not in friend list yet
+ * @param pos peer to connect to
*/
static void
attempt_connect (struct PeerList *pos)
* @param cls closure, identifies the entry on the
* message queue that was transmitted and the
* client responsible for queueing the message
- * @param rl identifies plugin used for the transmission for
- * this neighbour; needs to be re-enabled for
- * future transmissions
* @param target the peer receiving the message
* @param result GNUNET_OK on success, if the transmission
* failed, we should not tell the client to transmit
* Insert metadata into existing MD record (passed as cls).
*
* @param cls metadata to add to
+ * @param plugin_name name of the plugin that generated the meta data
* @param type type of entry to insert
* @param format format of data
* @param data_mime_type mime type of data
* @param data value of the meta data
- * @param data_size number of bytes in data
+ * @param data_len number of bytes in data
* @return always 0
*/
static int