summaryrefslogtreecommitdiff
path: root/sys/lib
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2002-03-14 03:16:15 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2002-03-14 03:16:15 +0000
commite63dc855fe4ff1aa0029ebf9813134860a34ccdf (patch)
treec2aa960c67a99a878c8902943399029fa598683f /sys/lib
parent71eb96ce8a9190e7ffeccbabd7a5ec4f3b4fc72f (diff)
Final __P removal plus some cosmetic fixups
Diffstat (limited to 'sys/lib')
-rw-r--r--sys/lib/libsa/alloc.c10
-rw-r--r--sys/lib/libsa/arp.c4
-rw-r--r--sys/lib/libsa/bootparam.c16
-rw-r--r--sys/lib/libsa/cread.c4
-rw-r--r--sys/lib/libsa/net.h15
-rw-r--r--sys/lib/libsa/printf.c6
-rw-r--r--sys/lib/libsa/rarp.c4
-rw-r--r--sys/lib/libsa/stand.h4
8 files changed, 31 insertions, 32 deletions
diff --git a/sys/lib/libsa/alloc.c b/sys/lib/libsa/alloc.c
index 0d90622c914..34fcf0aba79 100644
--- a/sys/lib/libsa/alloc.c
+++ b/sys/lib/libsa/alloc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: alloc.c,v 1.5 1997/08/01 21:57:09 pefo Exp $ */
+/* $OpenBSD: alloc.c,v 1.6 2002/03/14 03:16:09 millert Exp $ */
/* $NetBSD: alloc.c,v 1.6 1997/02/04 18:36:33 thorpej Exp $ */
/*
@@ -116,7 +116,7 @@ struct fl {
} *freelist = (struct fl *)0;
#ifdef HEAP_START
-static char *top = (char*)HEAP_START;
+static char *top = (char *)HEAP_START;
#else
extern char end[];
static char *top = end;
@@ -174,7 +174,7 @@ alloc(size)
size = ALIGN(sizeof (struct fl *));
top += ALIGN(sizeof(unsigned)) + ALIGN(size);
#ifdef HEAP_LIMIT
- if (top > (char*)HEAP_LIMIT)
+ if (top > (char *)HEAP_LIMIT)
panic("heap full (0x%lx+%u)", help, size);
#endif
*(unsigned *)help = ALIGN(size);
@@ -191,7 +191,7 @@ alloc(size)
found:
#endif
/* remove from freelist */
- help = (char*)*f;
+ help = (char *)*f;
*f = (*f)->next;
#ifdef ALLOC_TRACE
printf("=%p (origsize %u)\n", help + ALIGN(sizeof(unsigned)),
@@ -206,7 +206,7 @@ free(ptr, size)
unsigned size; /* only for consistence check */
{
register struct fl *f =
- (struct fl *)((char*)ptr - ALIGN(sizeof(unsigned)));
+ (struct fl *)((char *)ptr - ALIGN(sizeof(unsigned)));
#ifdef ALLOC_TRACE
printf("free(%p, %u) (origsize %u)\n", ptr, size, f->size);
#endif
diff --git a/sys/lib/libsa/arp.c b/sys/lib/libsa/arp.c
index 7196a50ea8a..aaad7fa7366 100644
--- a/sys/lib/libsa/arp.c
+++ b/sys/lib/libsa/arp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: arp.c,v 1.8 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: arp.c,v 1.9 2002/03/14 03:16:09 millert Exp $ */
/* $NetBSD: arp.c,v 1.15 1996/10/13 02:28:58 christos Exp $ */
/*
@@ -107,7 +107,7 @@ arpwhohas(d, addr)
printf("arpwhohas: send request for %s\n", inet_ntoa(addr));
#endif
- bzero((char*)&wbuf.data, sizeof(wbuf.data));
+ bzero((char *)&wbuf.data, sizeof(wbuf.data));
ah = &wbuf.data.arp;
ah->arp_hrd = htons(ARPHRD_ETHER);
ah->arp_pro = htons(ETHERTYPE_IP);
diff --git a/sys/lib/libsa/bootparam.c b/sys/lib/libsa/bootparam.c
index 10f7844ffc8..46691b4b832 100644
--- a/sys/lib/libsa/bootparam.c
+++ b/sys/lib/libsa/bootparam.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bootparam.c,v 1.9 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: bootparam.c,v 1.10 2002/03/14 03:16:09 millert Exp $ */
/* $NetBSD: bootparam.c,v 1.10 1996/10/14 21:16:55 thorpej Exp $ */
/*
@@ -146,7 +146,7 @@ bp_whoami(sockfd)
args->vers = htonl(BOOTPARAM_VERS);
args->proc = htonl(BOOTPARAM_WHOAMI);
args->arglen = htonl(sizeof(struct xdr_inaddr));
- send_tail = (char*) &args->xina;
+ send_tail = (char *)&args->xina;
/*
* append encapsulated data (client IP address)
@@ -160,7 +160,7 @@ bp_whoami(sockfd)
/* rpc_call will set d->destport */
len = rpc_call(d, PMAPPROG, PMAPVERS, PMAPPROC_CALLIT,
- args, send_tail - (char*)args,
+ args, send_tail - (char *)args,
repl, sizeof(*repl));
if (len < 8) {
printf("bootparamd: 'whoami' call failed\n");
@@ -194,7 +194,7 @@ bp_whoami(sockfd)
printf("bp_whoami: short reply, %d < %d\n", len, x);
return (-1);
}
- recv_head = (char*) repl->capsule;
+ recv_head = (char *)repl->capsule;
/* client name */
hostnamelen = MAXHOSTNAMELEN-1;
@@ -254,8 +254,8 @@ bp_getfile(sockfd, key, serv_addr, pathname)
return (-1);
}
- send_tail = (char*) sdata.d;
- recv_head = (char*) rdata.d;
+ send_tail = (char *)sdata.d;
+ recv_head = (char *)rdata.d;
/*
* Build request message.
@@ -280,14 +280,14 @@ bp_getfile(sockfd, key, serv_addr, pathname)
rlen = rpc_call(d,
BOOTPARAM_PROG, BOOTPARAM_VERS, BOOTPARAM_GETFILE,
- sdata.d, send_tail - (char*)sdata.d,
+ sdata.d, send_tail - (char *)sdata.d,
rdata.d, sizeof(rdata.d));
if (rlen < 4) {
RPC_PRINTF(("bp_getfile: short reply\n"));
errno = EBADRPC;
return (-1);
}
- recv_head = (char*) rdata.d;
+ recv_head = (char *)rdata.d;
/*
* Parse result message.
diff --git a/sys/lib/libsa/cread.c b/sys/lib/libsa/cread.c
index 90bee49cfd3..8d197552580 100644
--- a/sys/lib/libsa/cread.c
+++ b/sys/lib/libsa/cread.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cread.c,v 1.8 1999/02/14 20:07:46 mickey Exp $ */
+/* $OpenBSD: cread.c,v 1.9 2002/03/14 03:16:10 millert Exp $ */
/* $NetBSD: cread.c,v 1.2 1997/02/04 18:38:20 thorpej Exp $ */
/*
@@ -210,7 +210,7 @@ open(fname, mode)
#endif
goto errout;
- s->stream.next_in = s->inbuf = (unsigned char*)alloc(Z_BUFSIZE);
+ s->stream.next_in = s->inbuf = (unsigned char *)alloc(Z_BUFSIZE);
if(!s->inbuf) {
inflateEnd(&(s->stream));
goto errout;
diff --git a/sys/lib/libsa/net.h b/sys/lib/libsa/net.h
index f93b96a8417..33f1847875d 100644
--- a/sys/lib/libsa/net.h
+++ b/sys/lib/libsa/net.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: net.h,v 1.4 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: net.h,v 1.5 2002/03/14 03:16:10 millert Exp $ */
/* $NetBSD: net.h,v 1.10 1995/10/20 00:46:30 cgd Exp $ */
/*
@@ -98,17 +98,16 @@ int rarp_getipaddress(int);
/* Link functions: */
ssize_t sendether(struct iodesc *d, void *pkt, size_t len,
- u_char *dea, int etype);
+ u_char *dea, int etype);
ssize_t readether(struct iodesc *d, void *pkt, size_t len,
- time_t tleft, u_int16_t *etype);
+ time_t tleft, u_int16_t *etype);
ssize_t sendudp(struct iodesc *, void *, size_t);
ssize_t readudp(struct iodesc *, void *, size_t, time_t);
-ssize_t sendrecv __P((struct iodesc *,
- ssize_t (*)(struct iodesc *, void *, size_t),
- void *, size_t,
- ssize_t (*)(struct iodesc *, void *, size_t, time_t),
- void *, size_t));
+ssize_t sendrecv(struct iodesc *,
+ ssize_t (*)(struct iodesc *, void *, size_t), void *, size_t,
+ ssize_t (*)(struct iodesc *, void *, size_t, time_t),
+ void *, size_t);
/* Utilities: */
char *ether_sprintf(u_char *);
diff --git a/sys/lib/libsa/printf.c b/sys/lib/libsa/printf.c
index ce9a6a6070d..4dfe0ea69de 100644
--- a/sys/lib/libsa/printf.c
+++ b/sys/lib/libsa/printf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: printf.c,v 1.15 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: printf.c,v 1.16 2002/03/14 03:16:10 millert Exp $ */
/* $NetBSD: printf.c,v 1.10 1996/11/30 04:19:21 gwr Exp $ */
/*-
@@ -69,8 +69,8 @@
#include "stand.h"
-static void kprintn __P((void (*)(int), u_long, int));
-static void kdoprnt __P((void (*)(int), const char *, va_list));
+static void kprintn(void (*)(int), u_long, int);
+static void kdoprnt(void (*)(int), const char *, va_list);
#ifndef STRIPPED
static void sputchar(int);
diff --git a/sys/lib/libsa/rarp.c b/sys/lib/libsa/rarp.c
index 7113d2cb183..e022239e958 100644
--- a/sys/lib/libsa/rarp.c
+++ b/sys/lib/libsa/rarp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rarp.c,v 1.7 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: rarp.c,v 1.8 2002/03/14 03:16:10 millert Exp $ */
/* $NetBSD: rarp.c,v 1.13 1996/10/13 02:29:05 christos Exp $ */
/*
@@ -91,7 +91,7 @@ rarp_getipaddress(sock)
printf("rarp: d=%x\n", (u_int)d);
#endif
- bzero((char*)&wbuf.data, sizeof(wbuf.data));
+ bzero((char *)&wbuf.data, sizeof(wbuf.data));
ap = &wbuf.data.arp;
ap->arp_hrd = htons(ARPHRD_ETHER);
ap->arp_pro = htons(ETHERTYPE_IP);
diff --git a/sys/lib/libsa/stand.h b/sys/lib/libsa/stand.h
index bcef6c26974..e455a713206 100644
--- a/sys/lib/libsa/stand.h
+++ b/sys/lib/libsa/stand.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: stand.h,v 1.37 2002/03/14 01:27:07 millert Exp $ */
+/* $OpenBSD: stand.h,v 1.38 2002/03/14 03:16:10 millert Exp $ */
/* $NetBSD: stand.h,v 1.18 1996/11/30 04:35:51 gwr Exp $ */
/*-
@@ -153,7 +153,7 @@ __dead void _rtt(void) __attribute__((noreturn));
#define bcmp(s1,s2,n) (memcmp((s2),(s1),(n)))
#define bcopy(s1,s2,n) ((void)memcpy((s2),(s1),(n)))
void *memcpy(void *, const void *, size_t);
-int memcmp(const void *, const void*, size_t);
+int memcmp(const void *, const void *, size_t);
char *strncpy(char *, const char *, size_t);
char *strcpy(char *, const char *);
int strncmp(const char *, const char *, size_t);