gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [libmicrohttpd] 02/02: Added more comments for start upgrad


From: gnunet
Subject: [GNUnet-SVN] [libmicrohttpd] 02/02: Added more comments for start upgrade callback function.
Date: Mon, 15 May 2017 19:22:11 +0200

This is an automated email from the git hooks/post-receive script.

karlson2k pushed a commit to branch master
in repository libmicrohttpd.

commit 64b53a4e7c904a7dd9ce03e38bae75edd06902b5
Author: Evgeny Grin (Karlson2k) <address@hidden>
AuthorDate: Mon May 15 20:06:09 2017 +0300

    Added more comments for start upgrade callback function.
---
 src/examples/upgrade_example.c | 8 ++++++++
 src/include/microhttpd.h       | 3 +++
 2 files changed, 11 insertions(+)

diff --git a/src/examples/upgrade_example.c b/src/examples/upgrade_example.c
index 7a893d2f..af081408 100644
--- a/src/examples/upgrade_example.c
+++ b/src/examples/upgrade_example.c
@@ -158,6 +158,9 @@ run_usock (void *cls)
  * but instead use #MHD_upgrade_action() for special operations
  * on @a sock.
  *
+ * Data forwarding to "upgraded" @a sock will be started as soon
+ * as this function return.
+ *
  * Except when in 'thread-per-connection' mode, implementations
  * of this function should never block (as it will still be called
  * from within the main event loop).
@@ -225,6 +228,11 @@ uh_cb (void *cls,
      a clean shutdown, as the we stop the daemon even if a worker thread
      is still running. Alas, this is a simple example... */
   pthread_detach (pt);
+
+  /* This callback must return as soon as possible. */
+
+  /* Data forwarding to "upgraded" socket will be started
+   * after return from this callback. */
 }
 
 
diff --git a/src/include/microhttpd.h b/src/include/microhttpd.h
index 58787d3a..d7b69136 100644
--- a/src/include/microhttpd.h
+++ b/src/include/microhttpd.h
@@ -2840,6 +2840,9 @@ MHD_upgrade_action (struct MHD_UpgradeResponseHandle *urh,
  * but instead use #MHD_upgrade_action() for special operations
  * on @a sock.
  *
+ * Data forwarding to "upgraded" @a sock will be started as soon
+ * as this function return.
+ *
  * Except when in 'thread-per-connection' mode, implementations
  * of this function should never block (as it will still be called
  * from within the main event loop).

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]