Skip to content

Commit 5873417

Browse files
committed
Use epoll
1 parent 705599b commit 5873417

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

contrib/multimaster/sockhub/sockhub.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,8 @@ void ShubLoop(Shub* shub)
323323
if (rc > 0) {
324324
#ifdef USE_EPOLL
325325
int j;
326-
for (j = 0; j < rc; j++) {
326+
int n = rc;
327+
for (j = 0; j < n; j++) {
327328
i = events[j].data.fd;
328329
fprintf(stderr, "events[j].events=%d, events[j].data.fd=%d\n", events[j].events, events[j].data.fd);
329330
if (events[j].events & EPOLLERR) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy