summaryrefslogtreecommitdiff
path: root/usr.sbin/ppp
diff options
context:
space:
mode:
authorbrian <brian@cvs.openbsd.org>1998-01-29 00:35:35 +0000
committerbrian <brian@cvs.openbsd.org>1998-01-29 00:35:35 +0000
commit0e1503b337a6ed9c97a1ed86a09d085bc77a887a (patch)
treef5485240857b4b199e2959a3d586560d3e18d5a3 /usr.sbin/ppp
parentbf3074b9e0aadaad1d658302ce5ac227c7a8f0a1 (diff)
Don't moan about not creating tunX.pid and ttyX.if if RELEASE_CRUNCH
is defined.
Diffstat (limited to 'usr.sbin/ppp')
-rw-r--r--usr.sbin/ppp/main.c7
-rw-r--r--usr.sbin/ppp/modem.c11
2 files changed, 14 insertions, 4 deletions
diff --git a/usr.sbin/ppp/main.c b/usr.sbin/ppp/main.c
index 1a5d5de8029..e0672ed03eb 100644
--- a/usr.sbin/ppp/main.c
+++ b/usr.sbin/ppp/main.c
@@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * $Id: main.c,v 1.16 1998/01/29 00:34:32 brian Exp $
+ * $Id: main.c,v 1.17 1998/01/29 00:35:33 brian Exp $
*
* TODO:
* o Add commands for traffic summary, version display, etc.
@@ -540,9 +540,12 @@ main(int argc, char **argv)
if (lockfile != NULL) {
fprintf(lockfile, "%d\n", (int) getpid());
fclose(lockfile);
- } else
+ }
+#ifndef RELEASE_CRUNCH
+ else
LogPrintf(LogALERT, "Warning: Can't create %s: %s\n",
pid_filename, strerror(errno));
+#endif
LogPrintf(LogPHASE, "PPP Started.\n");
diff --git a/usr.sbin/ppp/modem.c b/usr.sbin/ppp/modem.c
index 15c3472935c..428ab13cc87 100644
--- a/usr.sbin/ppp/modem.c
+++ b/usr.sbin/ppp/modem.c
@@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * $Id: modem.c,v 1.10 1998/01/21 02:13:38 brian Exp $
+ * $Id: modem.c,v 1.11 1998/01/29 00:35:34 brian Exp $
*
* TODO:
*/
@@ -403,8 +403,11 @@ LockModem(void)
if (lockfile != NULL) {
fprintf(lockfile, "tun%d\n", tunno);
fclose(lockfile);
- } else
+ }
+#ifndef RELEASE_CRUNCH
+ else
LogPrintf(LogALERT, "Warning: Can't create %s: %s\n", fn, strerror(errno));
+#endif
return 0;
}
@@ -416,8 +419,12 @@ UnlockModem(void)
return;
snprintf(fn, sizeof fn, "%s%s.if", _PATH_VARRUN, VarBaseDevice);
+#ifndef RELEASE_CRUNCH
if (ID0unlink(fn) == -1)
LogPrintf(LogALERT, "Warning: Can't remove %s: %s\n", fn, strerror(errno));
+#else
+ ID0unlink(fn);
+#endif
if (!(mode & MODE_DIRECT) && ID0uu_unlock(VarBaseDevice) == -1)
LogPrintf(LogALERT, "Warning: Can't uu_unlock %s\n", fn);