diff options
| author | Peter Wemm <peter@FreeBSD.org> | 1996-12-30 14:49:24 +0000 | 
|---|---|---|
| committer | Peter Wemm <peter@FreeBSD.org> | 1996-12-30 14:49:24 +0000 | 
| commit | fadfbc36c69cacda8edbb85a3b6f66bb7c0fcc6a (patch) | |
| tree | 60b0bf8f7dba5d31c17a9c9d4e40ad7657288f4d | |
| parent | df7da8069f277c0b117146127bcac14da6e9ef02 (diff) | |
Notes
| -rw-r--r-- | lib/libc/rpc/pmap_getport.c | 5 | 
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libc/rpc/pmap_getport.c b/lib/libc/rpc/pmap_getport.c index dd63a3757f40..0ddab7e349fb 100644 --- a/lib/libc/rpc/pmap_getport.c +++ b/lib/libc/rpc/pmap_getport.c @@ -30,7 +30,7 @@  #if defined(LIBC_SCCS) && !defined(lint)  /*static char *sccsid = "from: @(#)pmap_getport.c 1.9 87/08/11 Copyr 1984 Sun Micro";*/  /*static char *sccsid = "from: @(#)pmap_getport.c	2.2 88/08/01 4.0 RPCSRC";*/ -static char *rcsid = "$Id: pmap_getport.c,v 1.2 1995/05/30 05:41:24 rgrimes Exp $"; +static char *rcsid = "$Id: pmap_getport.c,v 1.3 1995/10/22 14:51:31 phk Exp $";  #endif  /* @@ -84,7 +84,8 @@ pmap_getport(address, program, version, protocol)  		}  		CLNT_DESTROY(client);  	} -	(void)close(socket); +	if (socket != -1) +		(void)close(socket);  	address->sin_port = 0;  	return (port);  }  | 
