aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-10-06 08:58:04 +0000
committerChristian Grothoff <christian@grothoff.org>2011-10-06 08:58:04 +0000
commit2c1e75c6dddcba773349971229f2e8fdbfd72f59 (patch)
tree6a6a13c124e9db2d4df58b209afc373414973a0a /src/include
parent29a8deb6ba442fe476accc22d1ca6fca654fe3f8 (diff)
downloadgnunet-2c1e75c6dddcba773349971229f2e8fdbfd72f59.tar.gz
gnunet-2c1e75c6dddcba773349971229f2e8fdbfd72f59.zip
vminko: new API to delete a TransmitContext (slightly modified patch from #1822)
Diffstat (limited to 'src/include')
-rw-r--r--src/include/gnunet_server_lib.h24
1 files changed, 20 insertions, 4 deletions
diff --git a/src/include/gnunet_server_lib.h b/src/include/gnunet_server_lib.h
index f03d9625d..5289a6270 100644
--- a/src/include/gnunet_server_lib.h
+++ b/src/include/gnunet_server_lib.h
@@ -463,10 +463,9 @@ GNUNET_SERVER_transmit_context_append_message (struct
463 463
464 464
465/** 465/**
466 * Execute a transmission context. If there is 466 * Execute a transmission context. If there is an error in the
467 * an error in the transmission, the receive_done 467 * transmission, the receive_done method will be called with an error
468 * method will be called with an error code (GNUNET_SYSERR), 468 * code (GNUNET_SYSERR), otherwise with GNUNET_OK.
469 * otherwise with GNUNET_OK.
470 * 469 *
471 * @param tc transmission context to use 470 * @param tc transmission context to use
472 * @param timeout when to time out and abort the transmission 471 * @param timeout when to time out and abort the transmission
@@ -476,6 +475,23 @@ GNUNET_SERVER_transmit_context_run (struct GNUNET_SERVER_TransmitContext *tc,
476 struct GNUNET_TIME_Relative timeout); 475 struct GNUNET_TIME_Relative timeout);
477 476
478 477
478/**
479 * Destroy a transmission context. This function must not be called
480 * after 'GNUNET_SERVER_transmit_context_run'.
481 *
482 * @param tc transmission context to destroy
483 * @param success code to give to 'GNUNET_SERVER_receive_done' for
484 * the client: GNUNET_OK to keep the connection open and
485 * continue to receive
486 * GNUNET_NO to close the connection (normal behavior)
487 * GNUNET_SYSERR to close the connection (signal
488 * serious error)
489 */
490void
491GNUNET_SERVER_transmit_context_destroy (struct GNUNET_SERVER_TransmitContext
492 *tc,
493 int success);
494
479 495
480/** 496/**
481 * The notification context is the key datastructure for a conveniance 497 * The notification context is the key datastructure for a conveniance