From 7f15d5828f6683f2490ef864a2176919549880d7 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 3 Mar 2003 23:53:35 +0000 Subject: Another pstrcpy() into malloc()ed buffer fix. Andrew Bartlett (This used to be commit bd0c84d60b703e89081838a7cfa1eb1b4f45ad0a) --- source3/smbd/statcache.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source3/smbd') diff --git a/source3/smbd/statcache.c b/source3/smbd/statcache.c index f4b613428a..b6e84ec9a5 100644 --- a/source3/smbd/statcache.c +++ b/source3/smbd/statcache.c @@ -106,8 +106,8 @@ void stat_cache_add( char *full_orig_name, char *orig_translated_path) DEBUG(0,("stat_cache_add: Out of memory !\n")); return; } - pstrcpy(scp->names, orig_name); - pstrcpy((scp->names+namelen+1), translated_path); + safe_strcpy(scp->names, orig_name, namelen); + safe_strcpy((scp->names+namelen+1), translated_path, namelen); scp->name_len = namelen; hash_insert(&stat_cache, (char *)scp, orig_name); } -- cgit