ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/ev_kqueue.c
(Generate patch)

Comparing libev/ev_kqueue.c (file contents):
Revision 1.9 by root, Tue Nov 6 00:10:04 2007 UTC vs.
Revision 1.10 by root, Tue Nov 6 00:52:33 2007 UTC

85 kqueue_changecnt = 0; 85 kqueue_changecnt = 0;
86 86
87 if (res < 0) 87 if (res < 0)
88 { 88 {
89 if (errno != EINTR) 89 if (errno != EINTR)
90 syserr (); 90 syserr ("(libev) kevent");
91 91
92 return; 92 return;
93 } 93 }
94 94
95 for (i = 0; i < res; ++i) 95 for (i = 0; i < res; ++i)
183} 183}
184 184
185static void 185static void
186kqueue_fork (EV_P) 186kqueue_fork (EV_P)
187{ 187{
188 for (;;)
189 {
188 kqueue_fd = kqueue (); 190 kqueue_fd = kqueue ();
191
192 if (kqueue_fd >= 0)
193 break;
194
195 syserr ("(libev) kqueue");
196 }
197
189 fcntl (kqueue_fd, F_SETFD, FD_CLOEXEC); 198 fcntl (kqueue_fd, F_SETFD, FD_CLOEXEC);
190 199
191 /* re-register interest in fds */ 200 /* re-register interest in fds */
192 fd_rearm_all (EV_A); 201 fd_rearm_all (EV_A);
193} 202}

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines