[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd] 06/07: MHD_start_daemon(): added stricter checks for bin
From: |
gnunet |
Subject: |
[libmicrohttpd] 06/07: MHD_start_daemon(): added stricter checks for bind() and listen() return values |
Date: |
Fri, 10 Nov 2023 15:40:15 +0100 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
commit c211e198c623f7c640fd06966dac268c5c010868
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Fri Nov 10 10:24:55 2023 +0300
MHD_start_daemon(): added stricter checks for bind() and listen() return
values
---
src/microhttpd/daemon.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c
index 12d687e2..f0b620d1 100644
--- a/src/microhttpd/daemon.c
+++ b/src/microhttpd/daemon.c
@@ -8036,7 +8036,7 @@ MHD_start_daemon_va (unsigned int flags,
#endif
#endif
}
- if (-1 == bind (listen_fd, servaddr, addrlen))
+ if (0 != bind (listen_fd, servaddr, addrlen))
{
#ifdef HAVE_MESSAGES
MHD_DLOG (daemon,
@@ -8066,8 +8066,8 @@ MHD_start_daemon_va (unsigned int flags,
}
}
#endif
- if (listen (listen_fd,
- (int) daemon->listen_backlog_size) < 0)
+ if (0 != listen (listen_fd,
+ (int) daemon->listen_backlog_size))
{
#ifdef HAVE_MESSAGES
MHD_DLOG (daemon,
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [libmicrohttpd] branch master updated (e62cd69d -> a5649931), gnunet, 2023/11/10
- [libmicrohttpd] 02/07: daemon.c: moved processing and checking of app-provided listen socket, gnunet, 2023/11/10
- [libmicrohttpd] 04/07: MHD_start_daemon(): added some asserts, gnunet, 2023/11/10
- [libmicrohttpd] 03/07: MHD_start_daemon(): mark listen as UNIX based on available information, gnunet, 2023/11/10
- [libmicrohttpd] 01/07: .gitlab-ci.yml: removed "keep-going" make flag, gnunet, 2023/11/10
- [libmicrohttpd] 06/07: MHD_start_daemon(): added stricter checks for bind() and listen() return values,
gnunet <=
- [libmicrohttpd] 05/07: MHD_D_DOES_SCKT_FIT_FDSET_(): simplified macro, gnunet, 2023/11/10
- [libmicrohttpd] 07/07: MHD_start_daemon(): added check for epoll FD to fit fd_set for external polling mode, gnunet, 2023/11/10