From 9de7abd8db1336ef6223503889656edd77f74a6b Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sun, 1 Dec 2002 04:11:20 +0000 Subject: Link less with smbmnt and smbumount. Also change from a pstrcpy() to a strncpy() to make it clear that we must operate on a PATH_MAX sized buffer. Andrew Bartlett (This used to be commit 49d9698ef08d66dc238b2e3469da8944b444dfa1) --- source3/client/smbumount.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source3/client') diff --git a/source3/client/smbumount.c b/source3/client/smbumount.c index 983ad44fa0..9ea3083a6f 100644 --- a/source3/client/smbumount.c +++ b/source3/client/smbumount.c @@ -90,7 +90,8 @@ canonicalize (char *path) if (realpath (path, canonical)) return canonical; - pstrcpy (canonical, path); + strncpy (canonical, path, PATH_MAX); + canonical[PATH_MAX] = '\0'; return canonical; } -- cgit