ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/branches/8.0.x/src/s_bsd_poll.c
(Generate patch)

Comparing ircd-hybrid/branches/8.0.x/src/s_bsd_poll.c (file contents):
Revision 1731 by michael, Sat Oct 27 21:09:19 2012 UTC vs.
Revision 1732 by michael, Fri Jan 11 12:57:19 2013 UTC

# Line 43 | Line 43
43  
44   static struct pollfd *pollfds;
45   static int pollmax = -1;  /* highest FD number */
46 static dlink_node *hookptr;
47
48 /*
49 * changing_fdlimit
50 *
51 * Resize pollfds array if necessary.
52 */
53 static void *
54 changing_fdlimit(va_list args)
55 {
56  int old_fdlimit = hard_fdlimit;
57
58  pass_callback(hookptr, va_arg(args, int));
59
60  if (hard_fdlimit != old_fdlimit)
61    pollfds = MyRealloc(pollfds, sizeof(struct pollfd) * hard_fdlimit);
62
63  return NULL;
64 }
46  
47   /*
48   * init_netio
# Line 78 | Line 59 | init_netio(void)
59  
60    for (fd = 0; fd < hard_fdlimit; fd++)
61      pollfds[fd].fd = -1;
81
82  hookptr = install_hook(fdlimit_cb, changing_fdlimit);
62   }
63  
64   /*

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)