diff options
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libc/stdlib/tfind.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/lib/libc/stdlib/tfind.c b/src/lib/libc/stdlib/tfind.c index 34b916db6c..ff6bcd742d 100644 --- a/src/lib/libc/stdlib/tfind.c +++ b/src/lib/libc/stdlib/tfind.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: tfind.c,v 1.4 2004/10/01 04:08:45 jsg Exp $ */ | 1 | /* $OpenBSD: tfind.c,v 1.5 2005/03/30 18:51:49 pat Exp $ */ |
| 2 | 2 | ||
| 3 | /* | 3 | /* |
| 4 | * Tree search generalized from Knuth (6.2.2) Algorithm T just like | 4 | * Tree search generalized from Knuth (6.2.2) Algorithm T just like |
| @@ -21,10 +21,8 @@ typedef struct node_t | |||
| 21 | 21 | ||
| 22 | /* find a node, or return 0 */ | 22 | /* find a node, or return 0 */ |
| 23 | void * | 23 | void * |
| 24 | tfind(vkey, vrootp, compar) | 24 | tfind(const void *vkey, void * const *vrootp, |
| 25 | const void *vkey; /* key to be found */ | 25 | int (*compar)(const void *, const void *)) |
| 26 | void *const *vrootp; /* address of the tree root */ | ||
| 27 | int (*compar)(const void *, const void *); | ||
| 28 | { | 26 | { |
| 29 | char *key = (char *)vkey; | 27 | char *key = (char *)vkey; |
| 30 | node **rootp = (node **)vrootp; | 28 | node **rootp = (node **)vrootp; |
