More SNtp debug 9

This commit is contained in:
Sergey Lyubka committed 2022-05-27 22:24:45 +01:00
1 parent 34c5f63c00
commit 6b50039863
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -4394,7 +4394,7 @@ static void mg_iotest(struct mg_mgr *mgr, int ms) {
eSELECT_READ | eSELECT_EXCEPT | eSELECT_WRITE);
}
#elif MG_ENABLE_POLL
size_t n = 0;
nfds_t n = 0;
for (struct mg_connection *c = mgr->conns; c != NULL; c = c->next) n++;
struct pollfd fds[n == 0 ? 1 : n]; // Avoid zero-length VLA
+1 -1
View File
@@ -476,7 +476,7 @@ static void mg_iotest(struct mg_mgr *mgr, int ms) {
eSELECT_READ | eSELECT_EXCEPT | eSELECT_WRITE);
}
#elif MG_ENABLE_POLL
size_t n = 0;
nfds_t n = 0;
for (struct mg_connection *c = mgr->conns; c != NULL; c = c->next) n++;
struct pollfd fds[n == 0 ? 1 : n]; // Avoid zero-length VLA