diff options
author | Volker Lendecke <vl@samba.org> | 2010-08-14 12:23:13 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2010-08-14 12:27:17 +0200 |
commit | 13a4922ae631578fcc88eb6b98a15361fd805186 (patch) | |
tree | b5ec4a5b63b1526282bce3beac91b2ca25fcceb1 | |
parent | 19280b65a5744ffc23fae1918f371582a237c195 (diff) | |
download | samba-13a4922ae631578fcc88eb6b98a15361fd805186.tar.gz samba-13a4922ae631578fcc88eb6b98a15361fd805186.tar.bz2 samba-13a4922ae631578fcc88eb6b98a15361fd805186.zip |
s3: Remove a conn NULL check from claim_connection
We've already dereferenced conn before
-rw-r--r-- | source3/smbd/connection.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/source3/smbd/connection.c b/source3/smbd/connection.c index 5acc8218b7..f4f4fc217b 100644 --- a/source3/smbd/connection.c +++ b/source3/smbd/connection.c @@ -127,7 +127,6 @@ bool claim_connection(connection_struct *conn, const char *name) struct connections_data crec; TDB_DATA dbuf; NTSTATUS status; - char addr[INET6_ADDRSTRLEN]; DEBUG(5,("claiming [%s]\n", name)); @@ -148,9 +147,7 @@ bool claim_connection(connection_struct *conn, const char *name) crec.start = time(NULL); strlcpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)); - strlcpy(crec.addr,conn?conn->client_address: - client_addr(get_client_fd(),addr,sizeof(addr)), - sizeof(crec.addr)); + strlcpy(crec.addr, conn->client_address, sizeof(crec.addr)); dbuf.dptr = (uint8 *)&crec; dbuf.dsize = sizeof(crec); |