From 6f864d0a973a7f3987d73132be311b7cfbd1ccfc Mon Sep 17 00:00:00 2001 From: brian Date: Sun, 5 Sep 2004 01:46:52 +0000 Subject: Make ppp WARNS=5 clean --- usr.sbin/ppp/ether.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'usr.sbin/ppp/ether.c') diff --git a/usr.sbin/ppp/ether.c b/usr.sbin/ppp/ether.c index ce0bfd2..c1461c9 100644 --- a/usr.sbin/ppp/ether.c +++ b/usr.sbin/ppp/ether.c @@ -110,7 +110,7 @@ struct etherdevice { #define device2ether(d) \ ((d)->type == ETHER_DEVICE ? (struct etherdevice *)d : NULL) -int +unsigned ether_DeviceSize(void) { return sizeof(struct etherdevice); @@ -121,7 +121,7 @@ ether_Write(struct physical *p, const void *v, size_t n) { struct etherdevice *dev = device2ether(p->handler); - return NgSendData(p->fd, dev->hook, v, n) == -1 ? -1 : n; + return NgSendData(p->fd, dev->hook, v, n) == -1 ? -1 : (ssize_t)n; } static ssize_t @@ -191,7 +191,7 @@ ether_Slot(struct physical *p) static void ether_device2iov(struct device *d, struct iovec *iov, int *niov, - int maxiov, int *auxfd, int *nauxfd) + int maxiov __unused, int *auxfd, int *nauxfd) { struct etherdevice *dev = device2ether(d); int sz = physical_MaxDeviceSize(); @@ -343,7 +343,7 @@ static const struct device baseetherdevice = { struct device * ether_iov2device(int type, struct physical *p, struct iovec *iov, int *niov, - int maxiov, int *auxfd, int *nauxfd) + int maxiov __unused, int *auxfd, int *nauxfd) { if (type == ETHER_DEVICE) { struct etherdevice *dev = (struct etherdevice *)iov[(*niov)++].iov_base; @@ -443,8 +443,10 @@ ether_Create(struct physical *p) struct ng_mesg *resp; const struct hooklist *hlist; const struct nodeinfo *ninfo; - char *path, *sessionid, *mode; - int ifacelen, f; + char *path, *sessionid; + const char *mode; + size_t ifacelen; + unsigned f; dev = NULL; path = NULL; -- cgit v1.1