summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1996-08-22 00:36:00 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1996-08-22 00:36:00 +0000
commit32bb5c8b5aaa2322996d5499d65ed3d99ab6a3ca (patch)
tree67db7859c730d4d0df8be16cfe51458e739cb9fd
parent09f953a174464ba8c750219cfcf9ecdc344eba0d (diff)
__OpenBSD__
-rw-r--r--bin/ed/ed.h4
-rw-r--r--bin/sh/cd.c6
-rw-r--r--sys/net/bpf_filter.c4
-rw-r--r--sys/net/if_fddisubr.c4
-rw-r--r--sys/net/if_sl.c18
-rw-r--r--sys/net/if_strip.c18
-rw-r--r--sys/sys/timex.h4
-rw-r--r--usr.bin/m4/main.c6
-rw-r--r--usr.bin/m4/pathnames.h4
-rw-r--r--usr.bin/sup/src/ffilecopy.c6
-rw-r--r--usr.bin/tn3270/general/general.h4
-rw-r--r--usr.sbin/amd/config/os-bsd44.h8
-rw-r--r--usr.sbin/bootpd/getether.c2
-rw-r--r--usr.sbin/eeprom/getdate.y6
-rw-r--r--usr.sbin/pppd/nametoaddr.c6
15 files changed, 50 insertions, 50 deletions
diff --git a/bin/ed/ed.h b/bin/ed/ed.h
index 0e67781ab3f..c710b5bbd97 100644
--- a/bin/ed/ed.h
+++ b/bin/ed/ed.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ed.h,v 1.2 1996/06/23 14:20:00 deraadt Exp $ */
+/* $OpenBSD: ed.h,v 1.3 1996/08/22 00:35:17 deraadt Exp $ */
/* $NetBSD: ed.h,v 1.23 1995/03/21 09:04:40 cgd Exp $ */
/* ed.h: type and constant definitions for the ed editor. */
@@ -35,7 +35,7 @@
# include <sys/param.h> /* for MAXPATHLEN */
#endif
#include <errno.h>
-#if defined(sun) || defined(__NetBSD__)
+#if defined(sun) || defined(__NetBSD__) || defined(__OpenBSD__)
# include <limits.h>
#endif
#include <regex.h>
diff --git a/bin/sh/cd.c b/bin/sh/cd.c
index b00266ad4a7..140b32392a8 100644
--- a/bin/sh/cd.c
+++ b/bin/sh/cd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cd.c,v 1.6 1996/06/23 14:21:09 deraadt Exp $ */
+/* $OpenBSD: cd.c,v 1.7 1996/08/22 00:35:24 deraadt Exp $ */
/* $NetBSD: cd.c,v 1.15 1996/03/01 01:58:58 jtc Exp $ */
/*-
@@ -41,7 +41,7 @@
#if 0
static char sccsid[] = "@(#)cd.c 8.2 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: cd.c,v 1.6 1996/06/23 14:21:09 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: cd.c,v 1.7 1996/08/22 00:35:24 deraadt Exp $";
#endif
#endif /* not lint */
@@ -257,7 +257,7 @@ getpwd()
* c implementation of getcwd, that does not open a pipe to
* /bin/pwd.
*/
-#if defined(__NetBSD__) || defined(__svr4__)
+#if defined(__NetBSD__) || defined(__OpenBSD__) || defined(__svr4__)
if (getcwd(buf, sizeof(buf)) == NULL)
error("getcwd() failed");
curdir = savestr(buf);
diff --git a/sys/net/bpf_filter.c b/sys/net/bpf_filter.c
index 7042a50f702..cd685a2deab 100644
--- a/sys/net/bpf_filter.c
+++ b/sys/net/bpf_filter.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bpf_filter.c,v 1.3 1996/03/03 21:07:02 niklas Exp $ */
+/* $OpenBSD: bpf_filter.c,v 1.4 1996/08/22 00:35:50 deraadt Exp $ */
/* $NetBSD: bpf_filter.c,v 1.12 1996/02/13 22:00:00 christos Exp $ */
/*
@@ -52,7 +52,7 @@
#endif
#if defined(sparc) || defined(mips) || defined(ibm032) || \
- (defined(__NetBSD__) && !defined(UNALIGNED_ACCESS))
+ ((defined(__NetBSD__) || defined(__OpenBSD__)) && !defined(UNALIGNED_ACCESS))
#define BPF_ALIGN
#endif
diff --git a/sys/net/if_fddisubr.c b/sys/net/if_fddisubr.c
index eced9b4a4e0..dcca62283f3 100644
--- a/sys/net/if_fddisubr.c
+++ b/sys/net/if_fddisubr.c
@@ -109,7 +109,7 @@ extern struct ifqueue pkintrq;
#define llc_snap llc_un.type_snap
#endif
-#if defined(__bsdi__) || defined(__NetBSD__)
+#if defined(__bsdi__) || defined(__NetBSD__) || defined(__OpenBSD__)
#define RTALLOC1(a, b) rtalloc1(a, b)
#define ARPRESOLVE(a, b, c, d, e, f) arpresolve(a, b, c, d, e)
#define TYPEHTONS(t) (t)
@@ -589,7 +589,7 @@ fddi_ifattach(ifp)
ifp->if_hdrlen = 21;
ifp->if_mtu = FDDIMTU;
ifp->if_output = fddi_output;
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
for (ifa = ifp->if_addrlist.tqh_first; ifa != 0;
ifa = ifa->ifa_list.tqe_next)
#else
diff --git a/sys/net/if_sl.c b/sys/net/if_sl.c
index ff13a75b2ec..865626681df 100644
--- a/sys/net/if_sl.c
+++ b/sys/net/if_sl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sl.c,v 1.6 1996/08/09 09:59:19 niklas Exp $ */
+/* $OpenBSD: if_sl.c,v 1.7 1996/08/22 00:35:52 deraadt Exp $ */
/* $NetBSD: if_sl.c,v 1.39.4.1 1996/06/02 16:26:31 thorpej Exp $ */
/*
@@ -83,7 +83,7 @@
#include <sys/tty.h>
#include <sys/kernel.h>
#include <sys/conf.h>
-#if __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
#include <sys/systm.h>
#endif
@@ -166,7 +166,7 @@ Huh? Slip without inet?
Huh? SLMTU way too small.
#endif
#define SLIP_HIWAT roundup(50,CBSIZE)
-#ifndef NetBSD /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
#define CLISTRESERVE 1024 /* Can't let clists get too low */
#endif /* !NetBSD */
@@ -275,7 +275,7 @@ slopen(dev, tp)
tp->t_state |= TS_ISOPEN | TS_XCLUDE;
splx(s);
ttyflush(tp, FREAD | FWRITE);
-#ifdef NetBSD
+#if defined(__NetBSD__) || defined(__OpenBSD__)
/*
* make sure tty output queue is large enough
* to hold a full-sized packet (including frame
@@ -328,7 +328,7 @@ slclose(tp)
sc->sc_mp = 0;
sc->sc_buf = 0;
}
-#ifdef NetBSD
+#if defined(__NetBSD__) || defined(__OpenBSD__)
/* if necessary, install a new outq buffer of the appropriate size */
if (sc->sc_oldbufsize != 0) {
clfree(&tp->t_outq);
@@ -455,7 +455,7 @@ slstart(tp)
u_char bpfbuf[SLMTU + SLIP_HDRLEN];
register int len = 0;
#endif
-#ifndef NetBSD /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
extern int cfreecount;
#endif
@@ -476,7 +476,7 @@ slstart(tp)
if (sc == NULL)
return;
-#ifdef NetBSD /* XXX - cgd */
+#if defined(__NetBSD__) || defined(__OpenBSD__) /* XXX - cgd */
/*
* Do not remove the packet from the IP queue if it
* doesn't look like the packet will fit into the
@@ -548,7 +548,7 @@ slstart(tp)
#endif
sc->sc_if.if_lastchange = time;
-#ifndef __NetBSD__ /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
/*
* If system is getting low on clists, just flush our
* output queue (if the stuff was important, it'll get
@@ -595,7 +595,7 @@ slstart(tp)
* Put n characters at once
* into the tty output queue.
*/
-#ifdef __NetBSD__ /* XXX - cgd */
+#if defined(__NetBSD__) || defined(__OpenBSD__) /* XXX - cgd */
if (b_to_q((u_char *)bp, cp - bp,
#else
if (b_to_q((char *)bp, cp - bp,
diff --git a/sys/net/if_strip.c b/sys/net/if_strip.c
index 2a1b899c3ff..846d1689f94 100644
--- a/sys/net/if_strip.c
+++ b/sys/net/if_strip.c
@@ -109,7 +109,7 @@
#include <sys/tty.h>
#include <sys/kernel.h>
#include <sys/conf.h>
-#if __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
#include <sys/systm.h>
#endif
#include <sys/syslog.h>
@@ -135,7 +135,7 @@
#include <net/if_stripvar.h>
#include <net/slip.h>
-#ifdef __NetBSD__ /* XXX -- jrs */
+#if defined(__NetBSD__) || defined(__OpenBSD__) /* XXX -- jrs */
typedef u_char ttychar_t;
#else
typedef char ttychar_t;
@@ -198,7 +198,7 @@ typedef char ttychar_t;
#define STRIP_MTU_ONWIRE (SLMTU + 20 + STRIP_HDRLEN) /* (2*SLMTU+2 in sl.c */
#define SLIP_HIWAT roundup(50,CBSIZE)
-#ifndef __NetBSD__ /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
#define CLISTRESERVE 1024 /* Can't let clists get too low */
#endif /* !__NetBSD__ */
@@ -405,7 +405,7 @@ stripopen(dev, tp)
register struct st_softc *sc;
register int nstrip;
int error;
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
int s;
#endif
@@ -423,7 +423,7 @@ stripopen(dev, tp)
sc->sc_ttyp = tp;
sc->sc_if.if_baudrate = tp->t_ospeed;
ttyflush(tp, FREAD | FWRITE);
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
/*
* Make sure tty output queue is large enough
* to hold a full-sized packet (including frame
@@ -486,7 +486,7 @@ stripclose(tp)
sc->sc_rxbuf = 0;
sc->sc_txbuf = 0;
}
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
/* if necessary, install a new outq buffer of the appropriate size */
if (sc->sc_oldbufsize != 0) {
clfree(&tp->t_outq);
@@ -820,7 +820,7 @@ stripstart(tp)
u_char bpfbuf[SLMTU + SLIP_HDRLEN];
register int len = 0;
#endif
-#ifndef __NetBSD__ /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
extern int cfreecount;
#endif
for (;;) {
@@ -850,7 +850,7 @@ stripstart(tp)
return;
}
-#if defined(__NetBSD__) /* XXX - cgd */
+#if defined(__NetBSD__) || defined(__OpenBSD__) /* XXX - cgd */
/*
* Do not remove the packet from the IP queue if it
* doesn't look like the packet will fit into the
@@ -925,7 +925,7 @@ stripstart(tp)
#endif
sc->sc_if.if_lastchange = time;
-#ifndef __NetBSD__ /* XXX - cgd */
+#if !(defined(__NetBSD__) || defined(__OpenBSD__)) /* XXX - cgd */
/*
* If system is getting low on clists, just flush our
* output queue (if the stuff was important, it'll get
diff --git a/sys/sys/timex.h b/sys/sys/timex.h
index 9941d365d53..e9e6765e6f3 100644
--- a/sys/sys/timex.h
+++ b/sys/sys/timex.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: timex.h,v 1.4 1996/04/21 22:32:08 deraadt Exp $ */
+/* $OpenBSD: timex.h,v 1.5 1996/08/22 00:35:59 deraadt Exp $ */
/* $NetBSD: timex.h,v 1.2 1996/02/27 04:20:34 jonathan Exp $ */
/******************************************************************************
@@ -287,7 +287,7 @@ struct timex {
};
-#if defined(__FreeBSD__) || defined(__NetBSD__)
+#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
#ifndef _KERNEL
#include <sys/cdefs.h>
diff --git a/usr.bin/m4/main.c b/usr.bin/m4/main.c
index a226f50978e..234d83f4093 100644
--- a/usr.bin/m4/main.c
+++ b/usr.bin/m4/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.3 1996/06/26 05:36:14 deraadt Exp $ */
+/* $OpenBSD: main.c,v 1.4 1996/08/22 00:35:01 deraadt Exp $ */
/* $NetBSD: main.c,v 1.11 1996/01/13 23:25:26 pk Exp $ */
/*-
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 6/6/93";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.3 1996/06/26 05:36:14 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.4 1996/08/22 00:35:01 deraadt Exp $";
#endif
#endif /* not lint */
@@ -132,7 +132,7 @@ struct keyblk keywrds[] = { /* m4 keywords to be installed */
"syscmd", SYSCTYPE,
"sysval", SYSVTYPE,
-#if defined(unix) || defined(__NetBSD__)
+#if defined(unix) || defined(__NetBSD__) || defined(__OpenBSD__)
"unix", MACRTYPE,
#else
#ifdef vms
diff --git a/usr.bin/m4/pathnames.h b/usr.bin/m4/pathnames.h
index a6332c28aad..dd5bc976f30 100644
--- a/usr.bin/m4/pathnames.h
+++ b/usr.bin/m4/pathnames.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pathnames.h,v 1.2 1996/06/26 05:36:15 deraadt Exp $ */
+/* $OpenBSD: pathnames.h,v 1.3 1996/08/22 00:35:02 deraadt Exp $ */
/* $NetBSD: pathnames.h,v 1.6 1995/09/29 00:27:55 cgd Exp $ */
/*
@@ -49,7 +49,7 @@
#define UNIQUE 3 /* unique char location */
#endif
-#if defined(unix) || defined(__NetBSD__)
+#if defined(unix) || defined(__NetBSD__) || defined(__OpenBSD__)
#define _PATH_DIVNAME "/tmp/m4.0XXXXXX" /* unix diversion files */
#define UNIQUE 8 /* unique char location */
#endif
diff --git a/usr.bin/sup/src/ffilecopy.c b/usr.bin/sup/src/ffilecopy.c
index 3ac78041af5..218f2c19b37 100644
--- a/usr.bin/sup/src/ffilecopy.c
+++ b/usr.bin/sup/src/ffilecopy.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ffilecopy.c,v 1.2 1996/06/26 05:39:40 deraadt Exp $ */
+/* $OpenBSD: ffilecopy.c,v 1.3 1996/08/22 00:34:49 deraadt Exp $ */
/*
* Copyright (c) 1991 Carnegie Mellon University
@@ -60,7 +60,7 @@ FILE *here, *there;
if (fflush (there) == EOF) /* flush pending output */
return (EOF);
-#if defined(__386BSD__) || defined(__NetBSD__)
+#if defined(__386BSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
if ((here->_r) > 0) { /* flush buffered input */
i = write (therefile, here->_p, here->_r);
if (i != here->_r) return (EOF);
@@ -78,7 +78,7 @@ FILE *here, *there;
i = filecopy (herefile, therefile); /* fast file copy */
if (i < 0) return (EOF);
-#if defined(__386BSD__) || defined(__NetBSD__)
+#if defined(__386BSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
(here->_flags) |= __SEOF; /* indicate EOF */
#else
(here->_flag) |= _IOEOF; /* indicate EOF */
diff --git a/usr.bin/tn3270/general/general.h b/usr.bin/tn3270/general/general.h
index 0b92a5045e2..4574e3a22f8 100644
--- a/usr.bin/tn3270/general/general.h
+++ b/usr.bin/tn3270/general/general.h
@@ -1,4 +1,4 @@
-/* * $OpenBSD: general.h,v 1.4 1996/06/26 05:41:25 deraadt Exp $*/
+/* * $OpenBSD: general.h,v 1.5 1996/08/22 00:34:41 deraadt Exp $*/
/*-
* Copyright (c) 1988 The Regents of the University of California.
* All rights reserved.
@@ -50,7 +50,7 @@
#endif /* defined(unix) */
/* Define BSD equivalent mem* functions */
-#if defined(unix) && !defined(__NetBSD__)
+#if defined(unix) && !(defined(__NetBSD__) || defined(__OpenBSD__))
#define memcpy(dest,src,n) bcopy(src,dest,n)
#define memmove(dest,src,n) bcopy(src,dest,n)
#define memset(s,c,n) if (c == 0) { \
diff --git a/usr.sbin/amd/config/os-bsd44.h b/usr.sbin/amd/config/os-bsd44.h
index 21d4d3ef310..8763532e2ec 100644
--- a/usr.sbin/amd/config/os-bsd44.h
+++ b/usr.sbin/amd/config/os-bsd44.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: os-bsd44.h,v 1.4 1996/03/25 15:54:53 niklas Exp $ */
+/* $OpenBSD: os-bsd44.h,v 1.5 1996/08/22 00:34:28 deraadt Exp $ */
/*
* Copyright (c) 1990 Jan-Simon Pendry
@@ -70,7 +70,7 @@
/*
* 4.4 doesn't provide NIS, but NetBSD does.
*/
-#ifndef __NetBSD__
+#if !(defined(__NetBSD__) || defined(__OpenBSD__))
#undef HAS_NIS_MAPS
#endif
@@ -97,7 +97,7 @@
#undef MTAB_TYPE_UFS
#define MTAB_TYPE_UFS "ufs"
#define MTAB_TYPE_MFS "mfs"
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
#undef MTYPE_TYPE
#define MTYPE_TYPE char *
#endif
@@ -178,7 +178,7 @@ struct mntent {
* Type of a file handle
*/
#undef NFS_FH_TYPE
-#if __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
#define NFS_FH_TYPE void *
#endif
diff --git a/usr.sbin/bootpd/getether.c b/usr.sbin/bootpd/getether.c
index d131b50f7f8..12ac7d0832d 100644
--- a/usr.sbin/bootpd/getether.c
+++ b/usr.sbin/bootpd/getether.c
@@ -101,7 +101,7 @@ getether(ifname, eap)
#endif /* SUNOS */
-#if defined(__386BSD__) || defined(__NetBSD__)
+#if defined(__386BSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
/* Thanks to John Brezak <brezak@ch.hp.com> for this code. */
#include <sys/ioctl.h>
#include <net/if.h>
diff --git a/usr.sbin/eeprom/getdate.y b/usr.sbin/eeprom/getdate.y
index a653702da8b..68549384469 100644
--- a/usr.sbin/eeprom/getdate.y
+++ b/usr.sbin/eeprom/getdate.y
@@ -42,7 +42,7 @@ char *alloca ();
tricks are need, but defaults to using the gettimeofday system call.
Include <sys/time.h> if that will be used. */
-#if !defined (USG) && !defined (sgi) && !defined (__NetBSD__)
+#if !defined (USG) && !defined (sgi) && !defined (__NetBSD__) && !defined(__OpenBSD__)
#include <sys/time.h>
#endif
@@ -100,7 +100,7 @@ extern struct tm *localtime();
#if !defined(lint) && !defined(SABER)
static char RCS[] =
- "$Header: /cvs/OpenBSD/src/usr.sbin/eeprom/getdate.y,v 1.1 1995/10/18 08:47:33 deraadt Exp $";
+ "$Header: /cvs/OpenBSD/src/usr.sbin/eeprom/getdate.y,v 1.2 1996/08/22 00:34:05 deraadt Exp $";
#endif /* !defined(lint) && !defined(SABER) */
@@ -874,7 +874,7 @@ get_date(p, now)
#if sgi
ftz.timezone = (int) _timezone / 60;
#else /* not sgi */
-#ifdef __NetBSD__
+#if defined(__NetBSD__) || defined(__OpenBSD__)
ftz.timezone = 0;
#else /* neither sgi nor NetBSD */
#if defined (USG)
diff --git a/usr.sbin/pppd/nametoaddr.c b/usr.sbin/pppd/nametoaddr.c
index 8f8110c3aba..484f54894ab 100644
--- a/usr.sbin/pppd/nametoaddr.c
+++ b/usr.sbin/pppd/nametoaddr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nametoaddr.c,v 1.1 1996/03/25 15:55:50 niklas Exp $ */
+/* $OpenBSD: nametoaddr.c,v 1.2 1996/08/22 00:33:40 deraadt Exp $ */
/* From NetBSD: nametoaddr.c,v 1.3 1995/04/29 05:42:23 cgd Exp */
/*
@@ -30,12 +30,12 @@
from: static char rcsid[] =
"@(#) Header: nametoaddr.c,v 1.21 94/06/20 19:07:54 leres Exp (LBL)";
#else
-static char rcsid[] = "$OpenBSD: nametoaddr.c,v 1.1 1996/03/25 15:55:50 niklas Exp $";
+static char rcsid[] = "$OpenBSD: nametoaddr.c,v 1.2 1996/08/22 00:33:40 deraadt Exp $";
#endif
#endif
#include <stdio.h>
-#ifdef __NetBSD__
+#if define(__NetBSD__) || defined(__OpenBSD__)
#include <stdlib.h>
#include <string.h>
#endif