diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/rpc/netnamer.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libc/rpc/netnamer.c b/lib/libc/rpc/netnamer.c index 391cc20..41c5146 100644 --- a/lib/libc/rpc/netnamer.c +++ b/lib/libc/rpc/netnamer.c @@ -292,7 +292,8 @@ getnetid(key, ret) lookup[len] = 0; strcpy(ret, lookup); free(lookup); - fclose(fd); + if (fd != NULL) + fclose(fd); return (2); #else /* YP */ #ifdef DEBUG |