summaryrefslogtreecommitdiffstats
path: root/source/smbd/connection.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2003-03-22 13:47:42 +0000
committerAndrew Bartlett <abartlet@samba.org>2003-03-22 13:47:42 +0000
commitc91e76bddbe1244ddc8d12b092eba875834029ac (patch)
tree6ea6c1079c453969265bbb55ada3fb5900eb9ed5 /source/smbd/connection.c
parent5e20868fadc4e01ea09639bc57c51d1eb687f78c (diff)
downloadsamba-c91e76bddbe1244ddc8d12b092eba875834029ac.tar.gz
samba-c91e76bddbe1244ddc8d12b092eba875834029ac.tar.xz
samba-c91e76bddbe1244ddc8d12b092eba875834029ac.zip
(merge from HEAD)
Small clenaup patches: - safe_string.h - don't assume that __FUNCTION__ is available - process.c - use new workaround from safe_string.h for the same - util.c - Show how many bytes we smb_panic()ed trying to smb_xmalloc() - gencache.c - Keep valgrind quiet by always null terminating. - clistr.c - Add copyright - srvstr.h - move srvstr_push into a .c file again, as a real function. - srvstr.c - revive, with 'safe' checked srvstr_push - loadparm.c - set a default for the display charset. - connection.c - use safe_strcpy() Andrew Bartlett
Diffstat (limited to 'source/smbd/connection.c')
-rw-r--r--source/smbd/connection.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/smbd/connection.c b/source/smbd/connection.c
index a7636e889e3..17b5be8a7bb 100644
--- a/source/smbd/connection.c
+++ b/source/smbd/connection.c
@@ -171,14 +171,14 @@ BOOL claim_connection(connection_struct *conn, const char *name,int max_connecti
if (conn) {
crec.uid = conn->uid;
crec.gid = conn->gid;
- StrnCpy(crec.name,
+ safe_strcpy(crec.name,
lp_servicename(SNUM(conn)),sizeof(crec.name)-1);
}
crec.start = time(NULL);
crec.bcast_msg_flags = msg_flags;
- StrnCpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)-1);
- StrnCpy(crec.addr,conn?conn->client_address:client_addr(),sizeof(crec.addr)-1);
+ safe_strcpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)-1);
+ safe_strcpy(crec.addr,conn?conn->client_address:client_addr(),sizeof(crec.addr)-1);
dbuf.dptr = (char *)&crec;
dbuf.dsize = sizeof(crec);