diff options
author | deraadt <> | 2015-08-20 21:49:29 +0000 |
---|---|---|
committer | deraadt <> | 2015-08-20 21:49:29 +0000 |
commit | 189f85c7c7c7892a00f683ff1b1945c1db9cbc6c (patch) | |
tree | 906afedfff26ac2d6fec9dd54aa21fad26af98bf /src/lib/libc/stdlib/tsearch.c | |
parent | e6c90f43a8799602fd3816074341117c7ab33089 (diff) | |
download | openbsd-189f85c7c7c7892a00f683ff1b1945c1db9cbc6c.tar.gz openbsd-189f85c7c7c7892a00f683ff1b1945c1db9cbc6c.tar.bz2 openbsd-189f85c7c7c7892a00f683ff1b1945c1db9cbc6c.zip |
All these files include <stdlib.h>, so do not need to cast
malloc/calloc/realloc* returns.
Diffstat (limited to 'src/lib/libc/stdlib/tsearch.c')
-rw-r--r-- | src/lib/libc/stdlib/tsearch.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/libc/stdlib/tsearch.c b/src/lib/libc/stdlib/tsearch.c index a141085d2b..6a525e8bf0 100644 --- a/src/lib/libc/stdlib/tsearch.c +++ b/src/lib/libc/stdlib/tsearch.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: tsearch.c,v 1.8 2014/03/16 18:38:30 guenther Exp $ */ | 1 | /* $OpenBSD: tsearch.c,v 1.9 2015/08/20 21:49:29 deraadt 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 |
@@ -40,7 +40,7 @@ tsearch(const void *vkey, void **vrootp, | |||
40 | &(*rootp)->left : /* T3: follow left branch */ | 40 | &(*rootp)->left : /* T3: follow left branch */ |
41 | &(*rootp)->right; /* T4: follow right branch */ | 41 | &(*rootp)->right; /* T4: follow right branch */ |
42 | } | 42 | } |
43 | q = (node *) malloc(sizeof(node)); /* T5: key not found */ | 43 | q = malloc(sizeof(node)); /* T5: key not found */ |
44 | if (q != (struct node_t *)0) { /* make new node */ | 44 | if (q != (struct node_t *)0) { /* make new node */ |
45 | *rootp = q; /* link new node to old */ | 45 | *rootp = q; /* link new node to old */ |
46 | q->key = key; /* initialize new node */ | 46 | q->key = key; /* initialize new node */ |