libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit 33628f624579d1ecdc833e91aad3616c85623de9
parent 7138f3524c1cf4660c2a990e9cd0ddd10816ea88
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
Date:   Mon, 21 Sep 2020 11:22:30 +0300

mhd_itc_types.h: added macro for static initialisation

Diffstat:
Msrc/microhttpd/mhd_itc_types.h | 16++++++++++++++++
1 file changed, 16 insertions(+), 0 deletions(-)

diff --git a/src/microhttpd/mhd_itc_types.h b/src/microhttpd/mhd_itc_types.h @@ -47,6 +47,12 @@ struct MHD_itc_ int fd; }; +/** + * Static initialiser for struct MHD_itc_ + */ +#define MHD_ITC_STATIC_INIT_INVALID { -1 } + + #elif defined(_MHD_ITC_PIPE) /* **************** Standard UNIX ITC implementation by pipe ********** */ @@ -58,6 +64,11 @@ struct MHD_itc_ int fd[2]; }; +/** + * Static initialiser for struct MHD_itc_ + */ +#define MHD_ITC_STATIC_INIT_INVALID { -1, -1 } + #elif defined(_MHD_ITC_SOCKETPAIR) /* **************** ITC implementation by socket pair ********** */ @@ -72,6 +83,11 @@ struct MHD_itc_ MHD_socket sk[2]; }; +/** + * Static initialiser for struct MHD_itc_ + */ +#define MHD_ITC_STATIC_INIT_INVALID { MHD_INVALID_SOCKET, MHD_INVALID_SOCKET } + #endif /* _MHD_ITC_SOCKETPAIR */ #endif /* ! MHD_ITC_TYPES_H */