summaryrefslogtreecommitdiff
path: root/usr.sbin/pppoe/common.c
diff options
context:
space:
mode:
authorJason Wright <jason@cvs.openbsd.org>2002-09-08 04:33:47 +0000
committerJason Wright <jason@cvs.openbsd.org>2002-09-08 04:33:47 +0000
commit644c1e6569db30d6ed643782c4304ddb96ea5874 (patch)
treea03f7b75539066db79d1e734150a46cc2edc8058 /usr.sbin/pppoe/common.c
parent2294e26524e0b551fe55591783e8f6c7d6c818a7 (diff)
Fix a bunch of -pedantic errors
Diffstat (limited to 'usr.sbin/pppoe/common.c')
-rw-r--r--usr.sbin/pppoe/common.c20
1 files changed, 9 insertions, 11 deletions
diff --git a/usr.sbin/pppoe/common.c b/usr.sbin/pppoe/common.c
index bd710da9dea..14291ea7f4c 100644
--- a/usr.sbin/pppoe/common.c
+++ b/usr.sbin/pppoe/common.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: common.c,v 1.7 2002/09/06 19:57:10 deraadt Exp $ */
+/* $OpenBSD: common.c,v 1.8 2002/09/08 04:33:46 jason Exp $ */
/*
* Copyright (c) 2000 Network Security Technologies, Inc. http://www.netsec.net
@@ -66,7 +66,7 @@ void debugv(char *, struct iovec *, int);
int
runppp(bpffd, sysname)
int bpffd;
- char *sysname;
+ u_int8_t *sysname;
{
int socks[2], fdm, fds, closeit;
pid_t pid;
@@ -120,6 +120,8 @@ runppp(bpffd, sysname)
perror("execlp");
syslog(LOG_INFO, "%s exec failed: %m", PPP_PROG);
_exit(1);
+ /*NOTREACHED*/
+ return (-1);
}
int
@@ -147,10 +149,8 @@ bpf_to_ppp(pppfd, len, pkt)
}
int
-ppp_to_bpf(bfd, pppfd, myea, rmea, id)
- int bfd, pppfd;
- struct ether_addr *myea, *rmea;
- u_int16_t id;
+ppp_to_bpf(int bfd, int pppfd, struct ether_addr *myea,
+ struct ether_addr *rmea, u_int16_t id)
{
static u_int8_t *pktbuf = NULL;
struct pppoe_header ph;
@@ -243,10 +243,8 @@ out:
}
int
-send_padt(bpffd, src_ea, dst_ea, id)
- int bpffd;
- struct ether_addr *src_ea, *dst_ea;
- u_int16_t id;
+send_padt(int bpffd, struct ether_addr *src_ea,
+ struct ether_addr *dst_ea, u_int16_t id)
{
struct iovec iov[4];
struct pppoe_header ph;
@@ -273,7 +271,7 @@ u_int32_t
cookie_bake()
{
MD5_CTX ctx;
- char buf[40];
+ unsigned char buf[40];
u_int32_t x, y;
x = arc4random();