main.c (44539) | main.c (45126) |
---|---|
1/* 2 * User Process PPP 3 * 4 * Written by Toshiharu OHNO (tony-o@iij.ad.jp) 5 * 6 * Copyright (C) 1993, Internet Initiative Japan, Inc. All rights reserverd. 7 * 8 * Redistribution and use in source and binary forms are permitted 9 * provided that the above copyright notice and this paragraph are 10 * duplicated in all such forms and that any documentation, 11 * advertising materials, and other materials related to such 12 * distribution and use acknowledge that the software was developed 13 * by the Internet Initiative Japan, Inc. The name of the 14 * IIJ may not be used to endorse or promote products derived 15 * from this software without specific prior written permission. 16 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR 17 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED 18 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. 19 * | 1/* 2 * User Process PPP 3 * 4 * Written by Toshiharu OHNO (tony-o@iij.ad.jp) 5 * 6 * Copyright (C) 1993, Internet Initiative Japan, Inc. All rights reserverd. 7 * 8 * Redistribution and use in source and binary forms are permitted 9 * provided that the above copyright notice and this paragraph are 10 * duplicated in all such forms and that any documentation, 11 * advertising materials, and other materials related to such 12 * distribution and use acknowledge that the software was developed 13 * by the Internet Initiative Japan, Inc. The name of the 14 * IIJ may not be used to endorse or promote products derived 15 * from this software without specific prior written permission. 16 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR 17 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED 18 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. 19 * |
20 * $Id: main.c,v 1.150 1999/02/06 02:54:46 brian Exp $ | 20 * $Id: main.c,v 1.151 1999/03/07 01:02:38 brian Exp $ |
21 * 22 * TODO: 23 */ 24 25#include <sys/param.h> 26#include <netinet/in.h> 27#include <netinet/in_systm.h> 28#include <netinet/ip.h> --- 440 unchanged lines hidden (view full) --- 469 470 /* All our prompts and the diagnostic socket */ 471 descriptor_UpdateSet(&server.desc, &rfds, NULL, NULL, &nfds); 472 473 if (bundle_IsDead(bundle)) 474 /* Don't select - we'll be here forever */ 475 break; 476 | 21 * 22 * TODO: 23 */ 24 25#include <sys/param.h> 26#include <netinet/in.h> 27#include <netinet/in_systm.h> 28#include <netinet/ip.h> --- 440 unchanged lines hidden (view full) --- 469 470 /* All our prompts and the diagnostic socket */ 471 descriptor_UpdateSet(&server.desc, &rfds, NULL, NULL, &nfds); 472 473 if (bundle_IsDead(bundle)) 474 /* Don't select - we'll be here forever */ 475 break; 476 |
477 /* 478 * It's possible that we've had a signal since we last checked. If 479 * we don't check again before calling select(), we may end up stuck 480 * after having missed the event.... sig_Handle() tries to be as 481 * quick as possible if nothing is likely to have happened. 482 * This is only really likely if we block in open(... O_NONBLOCK) 483 * which will happen with a misconfigured device. 484 */ 485 if (sig_Handle()) 486 continue; 487 |
|
477 i = select(nfds, &rfds, &wfds, &efds, NULL); 478 479 if (i < 0 && errno != EINTR) { 480 log_Printf(LogERROR, "DoLoop: select(): %s\n", strerror(errno)); 481 if (log_IsKept(LogTIMER)) { 482 struct timeval t; 483 484 for (i = 0; i <= nfds; i++) { --- 83 unchanged lines hidden --- | 488 i = select(nfds, &rfds, &wfds, &efds, NULL); 489 490 if (i < 0 && errno != EINTR) { 491 log_Printf(LogERROR, "DoLoop: select(): %s\n", strerror(errno)); 492 if (log_IsKept(LogTIMER)) { 493 struct timeval t; 494 495 for (i = 0; i <= nfds; i++) { --- 83 unchanged lines hidden --- |