diff options
author | wollman <wollman@FreeBSD.org> | 2009-11-25 04:45:45 +0000 |
---|---|---|
committer | wollman <wollman@FreeBSD.org> | 2009-11-25 04:45:45 +0000 |
commit | a98dd21d5f02e42d66bdd19531580000647322e8 (patch) | |
tree | 01f0d0420123a2fbc4530d2d7bd607cbf6ee8049 /lib/libc/rpc | |
parent | 0bb16760a11c0384ebde0564be95b7c5711ce69e (diff) | |
download | FreeBSD-src-a98dd21d5f02e42d66bdd19531580000647322e8.zip FreeBSD-src-a98dd21d5f02e42d66bdd19531580000647322e8.tar.gz |
Eliminate more dead stores.
Found by: Clang static analyzer
MFC after: 7 days
Diffstat (limited to 'lib/libc/rpc')
-rw-r--r-- | lib/libc/rpc/getnetconfig.c | 4 | ||||
-rw-r--r-- | lib/libc/rpc/key_call.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/rpc/getnetconfig.c b/lib/libc/rpc/getnetconfig.c index 9baa224..e5db51a 100644 --- a/lib/libc/rpc/getnetconfig.c +++ b/lib/libc/rpc/getnetconfig.c @@ -412,13 +412,13 @@ void *handlep; * Noone needs these entries anymore, then frees them. * Make sure all info in netconfig_info structure has been reinitialized. */ - q = p = ni.head; + q = ni.head; ni.eof = ni.ref = 0; ni.head = NULL; ni.tail = NULL; mutex_unlock(&ni_lock); - while (q) { + while (q != NULL) { p = q->next; if (q->ncp->nc_lookups != NULL) free(q->ncp->nc_lookups); free(q->ncp); diff --git a/lib/libc/rpc/key_call.c b/lib/libc/rpc/key_call.c index 615f24d..6cc1139 100644 --- a/lib/libc/rpc/key_call.c +++ b/lib/libc/rpc/key_call.c @@ -302,7 +302,7 @@ int vers; void *localhandle; struct netconfig *nconf; struct netconfig *tpconf; - struct key_call_private *kcp = key_call_private_main; + struct key_call_private *kcp; struct timeval wait_time; struct utsname u; int main_thread; |