summaryrefslogtreecommitdiff
path: root/source3/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
commit1f499a79f5468e87d26b60ffe3aa375b91cadbef (patch)
tree095f7f163807060eadd42bf84a876aac1724b062 /source3/smbd/connection.c
parentb33cee92ed7e6729291616778963037f0d2f2f30 (diff)
downloadsamba-1f499a79f5468e87d26b60ffe3aa375b91cadbef.tar.gz
(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 (This used to be commit c91e76bddbe1244ddc8d12b092eba875834029ac)
Diffstat (limited to 'source3/smbd/connection.c')
-rw-r--r--source3/smbd/connection.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source3/smbd/connection.c b/source3/smbd/connection.c
index a7636e889e3..17b5be8a7bb 100644
--- a/source3/smbd/connection.c
+++ b/source3/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);