gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [libmicrohttpd] GNU libmicrohttpd branch master updated. 71


From: gitolite
Subject: [GNUnet-SVN] [libmicrohttpd] GNU libmicrohttpd branch master updated. 71806e71a661a0132f2c6d1b6c74a7ee73bb67e3
Date: Mon, 17 Oct 2016 10:21:42 +0200 (CEST)

The branch, master has been updated
       via  71806e71a661a0132f2c6d1b6c74a7ee73bb67e3 (commit)
      from  36d3808c1e7f9646e6a9ca1cad42a4297f12c5ee (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 71806e71a661a0132f2c6d1b6c74a7ee73bb67e3
Author: Christian Grothoff <address@hidden>
Date:   Mon Oct 17 10:21:40 2016 +0200

    remove bogus NULL check (this function must never be called with a NULL 
argument), rename as it is not static

-----------------------------------------------------------------------

Summary of changes:
 src/microhttpd/daemon.c   | 16 ++++++++--------
 src/microhttpd/internal.h |  3 ++-
 src/microhttpd/response.c |  2 +-
 3 files changed, 11 insertions(+), 10 deletions(-)

diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c
index 9da7508..5e2ff2c 100644
--- a/src/microhttpd/daemon.c
+++ b/src/microhttpd/daemon.c
@@ -916,16 +916,15 @@ call_handlers (struct MHD_Connection *con,
  * Finally cleanup upgrade-related resources. It should
  * be called when TLS buffers have been drained and
  * application signaled MHD by #MHD_UPGRADE_ACTION_CLOSE.
+ *
  * @param connection handle to the upgraded connection to clean
  */
 void
-cleanup_upgraded_connection (struct MHD_Connection *connection)
+MHD_cleanup_upgraded_connection_ (struct MHD_Connection *connection)
 {
-  struct MHD_Daemon *daemon;
+  struct MHD_Daemon *daemon = connection->daemon;
   struct MHD_UpgradeResponseHandle *urh;
-  if (NULL == connection)
-    return;
-  daemon = connection->daemon;
+
   urh = connection->urh;
   if (NULL == urh)
     return;
@@ -1267,7 +1266,7 @@ thread_main_connection_upgrade (struct MHD_Connection 
*con)
   MHD_semaphore_down (con->upgrade_sem);
   MHD_semaphore_destroy (con->upgrade_sem);
   con->upgrade_sem = NULL;
-  cleanup_upgraded_connection(con);
+  MHD_cleanup_upgraded_connection_ (con);
 }
 
 
@@ -2785,8 +2784,9 @@ MHD_run_from_select (struct MHD_Daemon *daemon,
       /* call generic forwarding function for passing data */
       process_urh (urh);
       /* cleanup connection if it was closed and all data was sent */
-      if (MHD_YES == urh->was_closed && 0 == urh->out_buffer_off)
-        cleanup_upgraded_connection (urh->connection);
+      if ( (MHD_YES == urh->was_closed) &&
+           (0 == urh->out_buffer_off) )
+        MHD_cleanup_upgraded_connection_ (urh->connection);
     }
 #endif
   MHD_cleanup_connections (daemon);
diff --git a/src/microhttpd/internal.h b/src/microhttpd/internal.h
index 9c5ac90..84f3f18 100644
--- a/src/microhttpd/internal.h
+++ b/src/microhttpd/internal.h
@@ -1727,9 +1727,10 @@ MHD_parse_arguments_ (struct MHD_Connection *connection,
  * Finally cleanup upgrade-related resources. It should
  * be called when TLS buffers have been drained and
  * application signaled MHD by #MHD_UPGRADE_ACTION_CLOSE.
+ *
  * @param connection handle to the upgraded connection to clean
  */
 void
-cleanup_upgraded_connection (struct MHD_Connection *connection);
+MHD_cleanup_upgraded_connection_ (struct MHD_Connection *connection);
 
 #endif
diff --git a/src/microhttpd/response.c b/src/microhttpd/response.c
index 0831840..b78d27e 100644
--- a/src/microhttpd/response.c
+++ b/src/microhttpd/response.c
@@ -660,7 +660,7 @@ MHD_upgrade_action (struct MHD_UpgradeResponseHandle *urh,
       }
 #endif
     /* 'upgraded' resources are not needed anymore - cleanup now */
-    cleanup_upgraded_connection (connection);
+    MHD_cleanup_upgraded_connection_ (connection);
     return MHD_YES;
   default:
     /* we don't understand this one */


hooks/post-receive
-- 
GNU libmicrohttpd



reply via email to

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