Searched refs:maxfd (Results 1 - 25 of 43) sorted by relevance

12

/freebsd-11-stable/contrib/openbsm/compat/
H A Dclosefrom.h38 int error, fd, maxfd; local
42 maxfd = sysconf(_SC_OPEN_MAX);
43 if (maxfd < 0)
44 maxfd = 16384;
45 for (fd = lowfd; fd <= maxfd; fd++)
/freebsd-11-stable/crypto/openssh/openbsd-compat/
H A Dbsd-closefrom.c71 long fd, maxfd; local
97 maxfd = sysconf(_SC_OPEN_MAX);
99 maxfd = getdtablesize();
101 if (maxfd < 0)
102 maxfd = OPEN_MAX;
104 for (fd = lowfd; fd < maxfd; fd++)
H A Dbsd-poll.c44 int saved_errno, ret, fd, maxfd = 0; local
55 maxfd = MAX(maxfd, fd);
58 nmemb = howmany(maxfd + 1 , NFDBITS);
89 ret = select(maxfd + 1, readfds, writefds, exceptfds, tvp);
/freebsd-11-stable/lib/libcasper/libcasper/
H A Dservice.c329 fd_add(fd_set *fdsp, int maxfd, int fd) argument
333 return (fd > maxfd ? fd : maxfd);
370 int fd, maxfd, minfd; local
384 maxfd = *procfdp;
387 maxfd = *sockp;
391 for (fd = STDERR_FILENO + 1; fd < maxfd; fd++) {
395 closefrom(maxfd + 1);
404 int maxfd, nfds; local
416 maxfd
[all...]
H A Dlibcasper_service.c216 int sock, maxfd, ret; local
229 maxfd = -1;
239 maxfd = sock > maxfd ? sock : maxfd;
242 if (maxfd == -1) {
246 maxfd++;
249 assert(maxfd <= (int)FD_SETSIZE);
250 ret = select(maxfd, &fds, NULL, NULL, NULL);
/freebsd-11-stable/usr.sbin/bluetooth/bthidd/
H A Dsession.c160 if (s->srv->maxfd == s->intr)
161 s->srv->maxfd --;
169 if (s->srv->maxfd == s->ctrl)
170 s->srv->maxfd --;
177 if (s->srv->maxfd == s->vkbd)
178 s->srv->maxfd --;
H A Dserver.c147 srv->maxfd = max(srv->ctrl, srv->intr);
191 n = select(srv->maxfd + 1, &rfdset, &wfdset, NULL, &tv);
197 srv->maxfd + 1, &rfdset, &wfdset, strerror(errno), errno);
203 for (fd = 0; fd < srv->maxfd + 1 && n > 0; fd ++) {
278 if (new_fd > srv->maxfd)
279 srv->maxfd = new_fd;
290 if (s->vkbd > srv->maxfd)
291 srv->maxfd = s->vkbd;
H A Dclient.c108 if (s->ctrl > srv->maxfd)
109 srv->maxfd = s->ctrl;
177 if (s->intr > srv->maxfd)
178 srv->maxfd = s->intr;
196 if (s->vkbd > srv->maxfd)
197 srv->maxfd = s->vkbd;
H A Dbthidd.h50 int32_t maxfd; /* max fd in sets */ member in struct:bthid_server
/freebsd-11-stable/contrib/apr/poll/unix/
H A Dselect.c38 int maxfd = -1; local
123 if ((int) fd > maxfd) {
124 maxfd = (int) fd;
130 rv = pipe_select(maxfd + 1, &readset, &writeset, &exceptset, tvptr);
135 rv = select(maxfd + 1, &readset, &writeset, &exceptset, tvptr);
188 int maxfd; member in struct:apr_pollset_private_t
216 pollset->p->maxfd = 0;
287 if ((int) fd > pollset->p->maxfd) {
288 pollset->p->maxfd = (int) fd;
329 if (((int) fd == pollset->p->maxfd)
[all...]
/freebsd-11-stable/contrib/dma/
H A Dlocal.c59 long maxfd; local
76 maxfd = sysconf(_SC_OPEN_MAX);
77 if (maxfd == -1)
78 maxfd = 1024; /* what can we do... */
80 for (i = 3; i <= maxfd; ++i)
/freebsd-11-stable/contrib/ntp/lib/isc/unix/
H A Dentropy.c392 int maxfd, fd; local
397 maxfd = -1;
406 maxfd = ISC_MAX(maxfd, fd);
419 maxfd = ISC_MAX(maxfd, fd);
424 maxfd = ISC_MAX(maxfd, fd);
433 if (maxfd < 0)
436 cc = select(maxfd
[all...]
/freebsd-11-stable/contrib/ipfilter/samples/
H A Dproxy.c237 int i, n, maxfd; local
240 maxfd = in;
241 if (out > maxfd)
242 maxfd = out;
243 if (net > maxfd)
244 maxfd = net;
267 n = select(maxfd + 1, &rd, &wr, NULL, NULL);
/freebsd-11-stable/contrib/blacklist/bin/
H A Dblacklistd.c340 addfd(struct pollfd **pfdp, bl_t **blp, size_t *nfd, size_t *maxfd, argument
346 if (*nfd >= *maxfd) {
347 *maxfd += 10;
348 *blp = realloc(*blp, sizeof(**blp) * *maxfd);
351 *pfdp = realloc(*pfdp, sizeof(**pfdp) * *maxfd);
514 size_t maxfd = 0; local
517 addfd(&pfd, &bl, &nfd, &maxfd, blsock[i]);
527 addfd(&pfd, &bl, &nfd, &maxfd, line);
531 addfd(&pfd, &bl, &nfd, &maxfd, _PATH_BLSOCK);
/freebsd-11-stable/contrib/nvi/cl/
H A Dcl_read.c154 int maxfd, nr, term_reset; local
229 maxfd = STDIN_FILENO;
232 if (sp->script->sh_master > maxfd)
233 maxfd = sp->script->sh_master;
235 switch (select(maxfd + 1, &rdfd, NULL, NULL, NULL)) {
/freebsd-11-stable/contrib/opie/
H A Dopieauto.c329 int maxfd = parents; local
338 if (select(maxfd + 1, &rfds, NULL, NULL, NULL) < 0)
349 if (s[i] == maxfd)
350 maxfd--;
374 if (s[i] > maxfd)
375 maxfd = s[i];
/freebsd-11-stable/usr.sbin/bluetooth/sdpd/
H A Dserver.h66 int32_t maxfd; /* max. descriptor is the set */ member in struct:server
H A Dserver.c197 srv->maxfd = (unsock > l2sock)? unsock : l2sock;
235 for (fd = 0; fd < srv->maxfd + 1; fd ++)
259 n = select(srv->maxfd + 1, &fdset, NULL, NULL, NULL);
265 srv->maxfd + 1, &fdset, strerror(errno), errno);
271 for (fd = 0; fd < srv->maxfd + 1 && n > 0; fd ++) {
391 if (srv->maxfd < cfd)
392 srv->maxfd = cfd;
575 if (fd == srv->maxfd)
576 srv->maxfd --;
/freebsd-11-stable/contrib/openbsm/bin/auditdistd/
H A Dauditdistd.c502 int fd, maxfd, ret; local
515 maxfd = -1;
522 maxfd = fd > maxfd ? fd : maxfd;
531 maxfd = fd > maxfd ? fd : maxfd;
537 PJDLOG_ASSERT(maxfd + 1 <= (int)FD_SETSIZE);
538 ret = select(maxfd
[all...]
/freebsd-11-stable/sbin/hastd/
H A Dhastd.c172 long maxfd; local
184 maxfd = sysconf(_SC_OPEN_MAX);
185 if (maxfd == -1) {
191 maxfd = 16384;
193 for (fd = 0; fd <= maxfd; fd++) {
1073 int fd, maxfd, ret; local
1086 maxfd = fd = proto_descriptor(cfg->hc_controlconn);
1095 maxfd = MAX(fd, maxfd);
1103 maxfd
[all...]
/freebsd-11-stable/contrib/telnet/telnet/
H A Dsys_bsd.c852 int maxfd = -1;
855 if ((netout || netin || netex) && net > maxfd)
856 maxfd = net;
858 if (ttyout && tout > maxfd)
859 maxfd = tout;
860 if (ttyin && tin > maxfd)
861 maxfd = tin;
862 tmp = howmany(maxfd+1, NFDBITS) * sizeof(fd_mask);
893 if ((c = select(maxfd + 1, ibitsp, obitsp, xbitsp,
850 int maxfd = -1; local
/freebsd-11-stable/crypto/openssh/
H A Dssh-keyscan.c73 int maxfd; variable
74 #define MAXCON (maxfd - 10)
410 if (s >= maxfd)
437 if (s >= maxfd || fdcon[s].c_status == CS_UNUSED)
630 while (select(maxfd, r, NULL, e, &seltime) == -1 &&
634 for (i = 0; i < maxfd; i++) {
799 maxfd = fdlim_get(1);
800 if (maxfd < 0)
802 if (maxfd > MAXMAXFD)
803 maxfd
[all...]
/freebsd-11-stable/usr.sbin/rrenumd/
H A Drrenumd.c534 int ch, i, maxfd = 0, send_counter = 0; local
622 if (s6 > maxfd)
623 maxfd = s6;
627 if (s4 > maxfd)
628 maxfd = s4;
640 if ((i = select(maxfd + 1, &select_fd, NULL, NULL,
/freebsd-11-stable/contrib/ipfilter/tools/
H A Dipfsyncd.c224 int maxfd; local
232 maxfd = nfd;
233 if (lfd > maxfd)
234 maxfd = lfd;
235 debug(2, "nfd %d lfd %d maxfd %d\n", nfd, lfd, maxfd);
248 n = select(maxfd + 1, &rd, NULL, NULL, NULL);
/freebsd-11-stable/contrib/unbound/util/
H A Dmini_event.c191 if((ret = select(base->maxfd+1, &r, &w, NULL, wait)) == -1) {
203 for(i=0; i<base->maxfd+1; i++) {
308 if(ev->ev_fd > ev->ev_base->maxfd)
309 ev->ev_base->maxfd = ev->ev_fd;

Completed in 216 milliseconds

12