aboutsummaryrefslogtreecommitdiff
path: root/src/lib/internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/internal.h')
-rw-r--r--src/lib/internal.h52
1 files changed, 44 insertions, 8 deletions
diff --git a/src/lib/internal.h b/src/lib/internal.h
index 4c3ceddc..4ea6528a 100644
--- a/src/lib/internal.h
+++ b/src/lib/internal.h
@@ -454,7 +454,7 @@ struct MHD_Request
454 * HTTP version string (i.e. http/1.1). Allocated 454 * HTTP version string (i.e. http/1.1). Allocated
455 * in pool. 455 * in pool.
456 */ 456 */
457 char *version; 457 char *version_s;
458 458
459 /** 459 /**
460 * Close connection after sending response? 460 * Close connection after sending response?
@@ -493,7 +493,6 @@ struct MHD_Request
493 */ 493 */
494 char *colon; 494 char *colon;
495 495
496
497 /** 496 /**
498 * Function used for reading HTTP request stream. 497 * Function used for reading HTTP request stream.
499 */ 498 */
@@ -515,11 +514,6 @@ struct MHD_Request
515#endif /* UPGRADE_SUPPORT */ 514#endif /* UPGRADE_SUPPORT */
516 515
517 /** 516 /**
518 * Foreign address (of length @e addr_len).
519 */
520 struct sockaddr_storage addr;
521
522 /**
523 * Thread handle for this connection (if we are using 517 * Thread handle for this connection (if we are using
524 * one thread per connection). 518 * one thread per connection).
525 */ 519 */
@@ -741,7 +735,23 @@ struct MHD_Connection
741 * Reference to the MHD_Daemon struct. 735 * Reference to the MHD_Daemon struct.
742 */ 736 */
743 struct MHD_Daemon *daemon; 737 struct MHD_Daemon *daemon;
738
739 /**
740 * We allow the main application to associate some pointer with the
741 * TCP connection (which may span multiple HTTP requests). Here is
742 * where we store it. (MHD does not know or care what it is).
743 * The location is given to the #MHD_NotifyConnectionCallback and
744 * also accessible via #MHD_CONNECTION_INFO_SOCKET_CONTEXT.
745 */
746 void *socket_context;
744 747
748#ifdef HTTPS_SUPPORT
749 /**
750 * State kept per TLS connection. Plugin-specific.
751 */
752 struct MHD_TLS_ConnectionState *tls_cs;
753#endif
754
745 /** 755 /**
746 * Information about the current request we are processing 756 * Information about the current request we are processing
747 * on this connection. 757 * on this connection.
@@ -749,6 +759,11 @@ struct MHD_Connection
749 struct MHD_Request request; 759 struct MHD_Request request;
750 760
751 /** 761 /**
762 * Foreign address (of length @e addr_len).
763 */
764 struct sockaddr_storage addr;
765
766 /**
752 * Length of the foreign address. 767 * Length of the foreign address.
753 */ 768 */
754 socklen_t addr_len; 769 socklen_t addr_len;
@@ -858,7 +873,7 @@ struct MHD_Daemon
858 /** 873 /**
859 * Closure for @e early_uri_logger_cb. 874 * Closure for @e early_uri_logger_cb.
860 */ 875 */
861 void *early_uri_logger_cls; 876 void *early_uri_logger_cb_cls;
862 877
863 /** 878 /**
864 * Function to call whenever a connection is started or 879 * Function to call whenever a connection is started or
@@ -881,6 +896,17 @@ struct MHD_Daemon
881 * Closure for @e unescape_cb. 896 * Closure for @e unescape_cb.
882 */ 897 */
883 void *unescape_cb_cls; 898 void *unescape_cb_cls;
899
900 /**
901 * Pointer to master daemon (NULL if this is the master)
902 */
903 struct MHD_Daemon *master;
904
905 /**
906 * Worker daemons (one per thread)
907 */
908 struct MHD_Daemon *worker_pool;
909
884 910
885#if HTTPS_SUPPORT 911#if HTTPS_SUPPORT
886 /** 912 /**
@@ -1135,6 +1161,16 @@ struct MHD_Daemon
1135 unsigned int ip_connection_limit; 1161 unsigned int ip_connection_limit;
1136 1162
1137 /** 1163 /**
1164 * Number of active parallel connections.
1165 */
1166 unsigned int connections;
1167
1168 /**
1169 * Number of worker daemons
1170 */
1171 unsigned int worker_pool_size;
1172
1173 /**
1138 * Default timeout in seconds for idle connections. 1174 * Default timeout in seconds for idle connections.
1139 */ 1175 */
1140 time_t connection_default_timeout; 1176 time_t connection_default_timeout;