doxy
[oweals/gnunet.git] / src / include / gnunet_nat_lib.h
index c521a560cd4f9c08ef2d44c31c6014b4f055ba17..3a1e9a6320dbb0b53a9313ff210a56363a657450 100644 (file)
@@ -84,7 +84,7 @@ struct GNUNET_NAT_Handle;
  * @param reversal_callback function to call if someone wants connection reversal from us,
  *        NULL if connection reversal is not supported
  * @param callback_cls closure for callback
- * @return NULL on error, otherwise handle that can be used to unregister 
+ * @return NULL on error, otherwise handle that can be used to unregister
  */
 struct GNUNET_NAT_Handle *
 GNUNET_NAT_register (const struct GNUNET_CONFIGURATION_Handle *cfg, int is_tcp,
@@ -117,8 +117,11 @@ GNUNET_NAT_test_address (struct GNUNET_NAT_Handle *h, const void *addr,
  *
  * @param h handle (used for configuration)
  * @param sa the address of the peer (IPv4-only)
+ *
+ * @return GNUNET_SYSERR on error, GNUNET_NO if nat client is disabled,
+ *         GNUNET_OK otherwise
  */
-void
+int
 GNUNET_NAT_run_client (struct GNUNET_NAT_Handle *h,
                        const struct sockaddr_in *sa);
 
@@ -145,7 +148,7 @@ struct GNUNET_NAT_Test;
  *
  * @param cls closure
  * @param success GNUNET_OK on success, GNUNET_NO on failure,
- *                GNUNET_SYSERR if the test could not be 
+ *                GNUNET_SYSERR if the test could not be
  *                properly started (internal failure)
  */
 typedef void (*GNUNET_NAT_TestCallback) (void *cls, int success);
@@ -227,7 +230,7 @@ struct GNUNET_NAT_MiniHandle;
  * general-purpose 'GNUNET_NAT_register' code).  However, it can be
  * used if specifically UPnP-based NAT traversal is to be used or
  * tested.
- * 
+ *
  * @param port port to map
  * @param is_tcp GNUNET_YES to map TCP, GNUNET_NO for UDP
  * @param ac function to call with mapping result
@@ -244,7 +247,7 @@ GNUNET_NAT_mini_map_start (uint16_t port, int is_tcp,
  * this function will give 'upnpc' 1s to remove tha mapping,
  * so while this function is non-blocking, a task will be
  * left with the scheduler for up to 1s past this call.
- * 
+ *
  * @param mini the handle
  */
 void