[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd] 04/08: internal.h: added macros for internal threads mod
From: |
gnunet |
Subject: |
[libmicrohttpd] 04/08: internal.h: added macros for internal threads modes detection |
Date: |
Tue, 07 Nov 2023 18:52:13 +0100 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
commit 827edab065b400717b186e44b0190e7f33628434
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Mon Nov 6 19:05:08 2023 +0300
internal.h: added macros for internal threads modes detection
---
src/microhttpd/internal.h | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/src/microhttpd/internal.h b/src/microhttpd/internal.h
index bd8b9ba0..0f8669f4 100644
--- a/src/microhttpd/internal.h
+++ b/src/microhttpd/internal.h
@@ -2533,6 +2533,29 @@ struct MHD_Daemon
#define MHD_D_IS_USING_EPOLL_(d) ((void) (d), 0)
#endif /* select() only */
+#if defined(MHD_USE_THREADS)
+/**
+ * Checks whether the @a d daemon is using internal polling thread
+ */
+#define MHD_D_IS_USING_THREADS_(d) \
+ (0 != (d->options & (MHD_USE_INTERNAL_POLLING_THREAD)))
+/**
+ * Checks whether the @a d daemon is using thread-per-connection mode
+ */
+#define MHD_D_IS_USING_THREAD_PER_CONN_(d) \
+ (0 != ((d)->options & MHD_USE_THREAD_PER_CONNECTION))
+#else /* ! MHD_USE_THREADS */
+/**
+ * Checks whether the @a d daemon is using internal polling thread
+ */
+#define MHD_D_IS_USING_THREADS_(d) ((void) d, 0)
+/**
+ * Checks whether the @a d daemon is using thread-per-connection mode
+ */
+#define MHD_D_IS_USING_THREAD_PER_CONN_(d) ((void) d, 0)
+#endif /* ! MHD_USE_THREADS */
+
+
#ifdef DAUTH_SUPPORT
/**
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [libmicrohttpd] branch master updated (cdf9b66c -> 9bdb6835), gnunet, 2023/11/07
- [libmicrohttpd] 04/08: internal.h: added macros for internal threads modes detection,
gnunet <=
- [libmicrohttpd] 03/08: internal.h: moved some macros, gnunet, 2023/11/07
- [libmicrohttpd] 06/08: mhd_sockets.h: cosmetics, gnunet, 2023/11/07
- [libmicrohttpd] 02/08: mhd_sockets.h: directly used detected system FD_SETSIZE, gnunet, 2023/11/07
- [libmicrohttpd] 01/08: Correction for cdf9b66c61a444c09ba7c9f4cee385cbd2b3bcdc, gnunet, 2023/11/07
- [libmicrohttpd] 05/08: daemon.c: cosmetics, gnunet, 2023/11/07
- [libmicrohttpd] 08/08: Used custom FD_SETSIZE in MHD_get_fdset2(), gnunet, 2023/11/07
- [libmicrohttpd] 07/08: Added MHD_OPTION_APP_FD_SETSIZE and MHD_FEATURE_FLEXIBLE_FD_SETSIZE, gnunet, 2023/11/07