diff options
author | millert <> | 2002-02-16 21:27:50 +0000 |
---|---|---|
committer | millert <> | 2002-02-16 21:27:50 +0000 |
commit | 052e020be6be85be6238c44b8386a61f8db7b6a4 (patch) | |
tree | 4cf8f905bd37027527533678516a258fa89e2696 /src/lib/libc/stdlib | |
parent | ee0af55ed65515812050f3b9a8d431c941b73eb8 (diff) | |
download | openbsd-052e020be6be85be6238c44b8386a61f8db7b6a4.tar.gz openbsd-052e020be6be85be6238c44b8386a61f8db7b6a4.tar.bz2 openbsd-052e020be6be85be6238c44b8386a61f8db7b6a4.zip |
Part one of userland __P removal. Done with a simple regexp with some minor hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically.
Diffstat (limited to 'src/lib/libc/stdlib')
-rw-r--r-- | src/lib/libc/stdlib/bsearch.c | 4 | ||||
-rw-r--r-- | src/lib/libc/stdlib/heapsort.c | 4 | ||||
-rw-r--r-- | src/lib/libc/stdlib/malloc.c | 6 | ||||
-rw-r--r-- | src/lib/libc/stdlib/merge.c | 8 | ||||
-rw-r--r-- | src/lib/libc/stdlib/qsort.c | 4 | ||||
-rw-r--r-- | src/lib/libc/stdlib/radixsort.c | 6 | ||||
-rw-r--r-- | src/lib/libc/stdlib/rand48.h | 4 | ||||
-rw-r--r-- | src/lib/libc/stdlib/tfind.c | 2 | ||||
-rw-r--r-- | src/lib/libc/stdlib/tsearch.c | 6 |
9 files changed, 22 insertions, 22 deletions
diff --git a/src/lib/libc/stdlib/bsearch.c b/src/lib/libc/stdlib/bsearch.c index eeef9bffc6..1903202b6c 100644 --- a/src/lib/libc/stdlib/bsearch.c +++ b/src/lib/libc/stdlib/bsearch.c | |||
@@ -32,7 +32,7 @@ | |||
32 | */ | 32 | */ |
33 | 33 | ||
34 | #if defined(LIBC_SCCS) && !defined(lint) | 34 | #if defined(LIBC_SCCS) && !defined(lint) |
35 | static char *rcsid = "$OpenBSD: bsearch.c,v 1.2 1996/08/19 08:33:26 tholo Exp $"; | 35 | static char *rcsid = "$OpenBSD: bsearch.c,v 1.3 2002/02/16 21:27:24 millert Exp $"; |
36 | #endif /* LIBC_SCCS and not lint */ | 36 | #endif /* LIBC_SCCS and not lint */ |
37 | 37 | ||
38 | #include <stdlib.h> | 38 | #include <stdlib.h> |
@@ -59,7 +59,7 @@ bsearch(key, base0, nmemb, size, compar) | |||
59 | const void *base0; | 59 | const void *base0; |
60 | size_t nmemb; | 60 | size_t nmemb; |
61 | register size_t size; | 61 | register size_t size; |
62 | register int (*compar) __P((const void *, const void *)); | 62 | register int (*compar)(const void *, const void *); |
63 | { | 63 | { |
64 | register const char *base = base0; | 64 | register const char *base = base0; |
65 | register int lim, cmp; | 65 | register int lim, cmp; |
diff --git a/src/lib/libc/stdlib/heapsort.c b/src/lib/libc/stdlib/heapsort.c index e3e4392e05..2770e5b977 100644 --- a/src/lib/libc/stdlib/heapsort.c +++ b/src/lib/libc/stdlib/heapsort.c | |||
@@ -35,7 +35,7 @@ | |||
35 | */ | 35 | */ |
36 | 36 | ||
37 | #if defined(LIBC_SCCS) && !defined(lint) | 37 | #if defined(LIBC_SCCS) && !defined(lint) |
38 | static char *rcsid = "$OpenBSD: heapsort.c,v 1.2 1996/08/19 08:33:32 tholo Exp $"; | 38 | static char *rcsid = "$OpenBSD: heapsort.c,v 1.3 2002/02/16 21:27:24 millert Exp $"; |
39 | #endif /* LIBC_SCCS and not lint */ | 39 | #endif /* LIBC_SCCS and not lint */ |
40 | 40 | ||
41 | #include <sys/types.h> | 41 | #include <sys/types.h> |
@@ -141,7 +141,7 @@ int | |||
141 | heapsort(vbase, nmemb, size, compar) | 141 | heapsort(vbase, nmemb, size, compar) |
142 | void *vbase; | 142 | void *vbase; |
143 | size_t nmemb, size; | 143 | size_t nmemb, size; |
144 | int (*compar) __P((const void *, const void *)); | 144 | int (*compar)(const void *, const void *); |
145 | { | 145 | { |
146 | register int cnt, i, j, l; | 146 | register int cnt, i, j, l; |
147 | register char tmp, *tmp1, *tmp2; | 147 | register char tmp, *tmp1, *tmp2; |
diff --git a/src/lib/libc/stdlib/malloc.c b/src/lib/libc/stdlib/malloc.c index 6fae6fe565..bca7bb7c4e 100644 --- a/src/lib/libc/stdlib/malloc.c +++ b/src/lib/libc/stdlib/malloc.c | |||
@@ -8,7 +8,7 @@ | |||
8 | */ | 8 | */ |
9 | 9 | ||
10 | #if defined(LIBC_SCCS) && !defined(lint) | 10 | #if defined(LIBC_SCCS) && !defined(lint) |
11 | static char rcsid[] = "$OpenBSD: malloc.c,v 1.46 2002/01/23 20:42:24 fgsch Exp $"; | 11 | static char rcsid[] = "$OpenBSD: malloc.c,v 1.47 2002/02/16 21:27:24 millert Exp $"; |
12 | #endif /* LIBC_SCCS and not lint */ | 12 | #endif /* LIBC_SCCS and not lint */ |
13 | 13 | ||
14 | /* | 14 | /* |
@@ -88,7 +88,7 @@ static char rcsid[] = "$OpenBSD: malloc.c,v 1.46 2002/01/23 20:42:24 fgsch Exp $ | |||
88 | * we use the unwrapped syscall _thread_sys_write() | 88 | * we use the unwrapped syscall _thread_sys_write() |
89 | */ | 89 | */ |
90 | # define write _thread_sys_write | 90 | # define write _thread_sys_write |
91 | ssize_t write __P((int, const void *, size_t)); | 91 | ssize_t write(int, const void *, size_t); |
92 | # undef malloc | 92 | # undef malloc |
93 | # undef realloc | 93 | # undef realloc |
94 | # undef free | 94 | # undef free |
@@ -243,7 +243,7 @@ static int malloc_utrace; | |||
243 | 243 | ||
244 | struct ut { void *p; size_t s; void *r; }; | 244 | struct ut { void *p; size_t s; void *r; }; |
245 | 245 | ||
246 | void utrace __P((struct ut *, int)); | 246 | void utrace(struct ut *, int); |
247 | 247 | ||
248 | #define UTRACE(a, b, c) \ | 248 | #define UTRACE(a, b, c) \ |
249 | if (malloc_utrace) \ | 249 | if (malloc_utrace) \ |
diff --git a/src/lib/libc/stdlib/merge.c b/src/lib/libc/stdlib/merge.c index 0a1015ad9d..345eb2fd8b 100644 --- a/src/lib/libc/stdlib/merge.c +++ b/src/lib/libc/stdlib/merge.c | |||
@@ -35,7 +35,7 @@ | |||
35 | */ | 35 | */ |
36 | 36 | ||
37 | #if defined(LIBC_SCCS) && !defined(lint) | 37 | #if defined(LIBC_SCCS) && !defined(lint) |
38 | static char *rcsid = "$OpenBSD: merge.c,v 1.3 1996/09/15 09:31:50 tholo Exp $"; | 38 | static char *rcsid = "$OpenBSD: merge.c,v 1.4 2002/02/16 21:27:24 millert Exp $"; |
39 | #endif /* LIBC_SCCS and not lint */ | 39 | #endif /* LIBC_SCCS and not lint */ |
40 | 40 | ||
41 | /* | 41 | /* |
@@ -99,7 +99,7 @@ mergesort(base, nmemb, size, cmp) | |||
99 | void *base; | 99 | void *base; |
100 | size_t nmemb; | 100 | size_t nmemb; |
101 | register size_t size; | 101 | register size_t size; |
102 | int (*cmp) __P((const void *, const void *)); | 102 | int (*cmp)(const void *, const void *); |
103 | { | 103 | { |
104 | register int i, sense; | 104 | register int i, sense; |
105 | int big, iflag; | 105 | int big, iflag; |
@@ -257,7 +257,7 @@ COPY: b = t; | |||
257 | void | 257 | void |
258 | setup(list1, list2, n, size, cmp) | 258 | setup(list1, list2, n, size, cmp) |
259 | size_t n, size; | 259 | size_t n, size; |
260 | int (*cmp) __P((const void *, const void *)); | 260 | int (*cmp)(const void *, const void *); |
261 | u_char *list1, *list2; | 261 | u_char *list1, *list2; |
262 | { | 262 | { |
263 | int i, length, size2, tmp, sense; | 263 | int i, length, size2, tmp, sense; |
@@ -332,7 +332,7 @@ static void | |||
332 | insertionsort(a, n, size, cmp) | 332 | insertionsort(a, n, size, cmp) |
333 | u_char *a; | 333 | u_char *a; |
334 | size_t n, size; | 334 | size_t n, size; |
335 | int (*cmp) __P((const void *, const void *)); | 335 | int (*cmp)(const void *, const void *); |
336 | { | 336 | { |
337 | u_char *ai, *s, *t, *u, tmp; | 337 | u_char *ai, *s, *t, *u, tmp; |
338 | int i; | 338 | int i; |
diff --git a/src/lib/libc/stdlib/qsort.c b/src/lib/libc/stdlib/qsort.c index 1c3020b595..d16ed7b0bd 100644 --- a/src/lib/libc/stdlib/qsort.c +++ b/src/lib/libc/stdlib/qsort.c | |||
@@ -32,14 +32,14 @@ | |||
32 | */ | 32 | */ |
33 | 33 | ||
34 | #if defined(LIBC_SCCS) && !defined(lint) | 34 | #if defined(LIBC_SCCS) && !defined(lint) |
35 | static char *rcsid = "$OpenBSD: qsort.c,v 1.5 1997/06/20 11:19:38 deraadt Exp $"; | 35 | static char *rcsid = "$OpenBSD: qsort.c,v 1.6 2002/02/16 21:27:24 millert Exp $"; |
36 | #endif /* LIBC_SCCS and not lint */ | 36 | #endif /* LIBC_SCCS and not lint */ |
37 | 37 | ||
38 | #include <sys/types.h> | 38 | #include <sys/types.h> |
39 | #include <stdlib.h> | 39 | #include <stdlib.h> |
40 | 40 | ||
41 | static __inline char *med3 __P((char *, char *, char *, int (*)())); | 41 | static __inline char *med3 __P((char *, char *, char *, int (*)())); |
42 | static __inline void swapfunc __P((char *, char *, int, int)); | 42 | static __inline void swapfunc(char *, char *, int, int); |
43 | 43 | ||
44 | #define min(a, b) (a) < (b) ? a : b | 44 | #define min(a, b) (a) < (b) ? a : b |
45 | 45 | ||
diff --git a/src/lib/libc/stdlib/radixsort.c b/src/lib/libc/stdlib/radixsort.c index 41ed962466..40d7c0789f 100644 --- a/src/lib/libc/stdlib/radixsort.c +++ b/src/lib/libc/stdlib/radixsort.c | |||
@@ -35,7 +35,7 @@ | |||
35 | */ | 35 | */ |
36 | 36 | ||
37 | #if defined(LIBC_SCCS) && !defined(lint) | 37 | #if defined(LIBC_SCCS) && !defined(lint) |
38 | static char *rcsid = "$OpenBSD: radixsort.c,v 1.3 1996/08/19 08:33:44 tholo Exp $"; | 38 | static char *rcsid = "$OpenBSD: radixsort.c,v 1.4 2002/02/16 21:27:24 millert Exp $"; |
39 | #endif /* LIBC_SCCS and not lint */ | 39 | #endif /* LIBC_SCCS and not lint */ |
40 | 40 | ||
41 | /* | 41 | /* |
@@ -61,8 +61,8 @@ typedef struct { | |||
61 | } stack; | 61 | } stack; |
62 | 62 | ||
63 | static __inline void simplesort | 63 | static __inline void simplesort |
64 | __P((const u_char **, int, int, const u_char *, u_int)); | 64 | (const u_char **, int, int, const u_char *, u_int); |
65 | static void r_sort_a __P((const u_char **, int, int, const u_char *, u_int)); | 65 | static void r_sort_a(const u_char **, int, int, const u_char *, u_int); |
66 | static void r_sort_b __P((const u_char **, | 66 | static void r_sort_b __P((const u_char **, |
67 | const u_char **, int, int, const u_char *, u_int)); | 67 | const u_char **, int, int, const u_char *, u_int)); |
68 | 68 | ||
diff --git a/src/lib/libc/stdlib/rand48.h b/src/lib/libc/stdlib/rand48.h index e7cb3e0333..afa49f65f3 100644 --- a/src/lib/libc/stdlib/rand48.h +++ b/src/lib/libc/stdlib/rand48.h | |||
@@ -10,7 +10,7 @@ | |||
10 | * of any kind. I shall in no event be liable for anything that happens | 10 | * of any kind. I shall in no event be liable for anything that happens |
11 | * to anyone/anything when using this software. | 11 | * to anyone/anything when using this software. |
12 | * | 12 | * |
13 | * $OpenBSD: rand48.h,v 1.2 1996/08/19 08:33:45 tholo Exp $ | 13 | * $OpenBSD: rand48.h,v 1.3 2002/02/16 21:27:24 millert Exp $ |
14 | */ | 14 | */ |
15 | 15 | ||
16 | #ifndef _RAND48_H_ | 16 | #ifndef _RAND48_H_ |
@@ -19,7 +19,7 @@ | |||
19 | #include <math.h> | 19 | #include <math.h> |
20 | #include <stdlib.h> | 20 | #include <stdlib.h> |
21 | 21 | ||
22 | void __dorand48 __P((unsigned short[3])); | 22 | void __dorand48(unsigned short[3]); |
23 | 23 | ||
24 | #define RAND48_SEED_0 (0x330e) | 24 | #define RAND48_SEED_0 (0x330e) |
25 | #define RAND48_SEED_1 (0xabcd) | 25 | #define RAND48_SEED_1 (0xabcd) |
diff --git a/src/lib/libc/stdlib/tfind.c b/src/lib/libc/stdlib/tfind.c index 9e5bd4b0f2..5c3b8c17f5 100644 --- a/src/lib/libc/stdlib/tfind.c +++ b/src/lib/libc/stdlib/tfind.c | |||
@@ -22,7 +22,7 @@ void * | |||
22 | tfind(vkey, vrootp, compar) | 22 | tfind(vkey, vrootp, compar) |
23 | const void *vkey; /* key to be found */ | 23 | const void *vkey; /* key to be found */ |
24 | void *const *vrootp; /* address of the tree root */ | 24 | void *const *vrootp; /* address of the tree root */ |
25 | int (*compar) __P((const void *, const void *)); | 25 | int (*compar)(const void *, const void *); |
26 | { | 26 | { |
27 | char *key = (char *)vkey; | 27 | char *key = (char *)vkey; |
28 | node **rootp = (node **)vrootp; | 28 | node **rootp = (node **)vrootp; |
diff --git a/src/lib/libc/stdlib/tsearch.c b/src/lib/libc/stdlib/tsearch.c index 562ace1845..0ad5866172 100644 --- a/src/lib/libc/stdlib/tsearch.c +++ b/src/lib/libc/stdlib/tsearch.c | |||
@@ -23,7 +23,7 @@ void * | |||
23 | tsearch(vkey, vrootp, compar) | 23 | tsearch(vkey, vrootp, compar) |
24 | const void *vkey; /* key to be located */ | 24 | const void *vkey; /* key to be located */ |
25 | void **vrootp; /* address of tree root */ | 25 | void **vrootp; /* address of tree root */ |
26 | int (*compar) __P((const void *, const void *)); | 26 | int (*compar)(const void *, const void *); |
27 | { | 27 | { |
28 | register node *q; | 28 | register node *q; |
29 | char *key = (char *)vkey; | 29 | char *key = (char *)vkey; |
@@ -54,7 +54,7 @@ void * | |||
54 | tdelete(vkey, vrootp, compar) | 54 | tdelete(vkey, vrootp, compar) |
55 | const void *vkey; /* key to be deleted */ | 55 | const void *vkey; /* key to be deleted */ |
56 | void **vrootp; /* address of the root of tree */ | 56 | void **vrootp; /* address of the root of tree */ |
57 | int (*compar) __P((const void *, const void *)); | 57 | int (*compar)(const void *, const void *); |
58 | { | 58 | { |
59 | node **rootp = (node **)vrootp; | 59 | node **rootp = (node **)vrootp; |
60 | char *key = (char *)vkey; | 60 | char *key = (char *)vkey; |
@@ -117,7 +117,7 @@ trecurse(root, action, level) | |||
117 | void | 117 | void |
118 | twalk(vroot, action) | 118 | twalk(vroot, action) |
119 | const void *vroot; /* Root of the tree to be walked */ | 119 | const void *vroot; /* Root of the tree to be walked */ |
120 | void (*action) __P((const void *, VISIT, int)); | 120 | void (*action)(const void *, VISIT, int); |
121 | { | 121 | { |
122 | node *root = (node *)vroot; | 122 | node *root = (node *)vroot; |
123 | 123 | ||