From 9365669a5988ea67764e051d626f664daf6596eb Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Fri, 22 Jul 2005 03:35:28 +0000 Subject: r8697: BUG 2908: make sure to allow for the trailing NULL (This used to be commit 3b505a824365222352be6a5ad2fb26586415a7a3) --- source3/smbd/msdfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'source3/smbd') diff --git a/source3/smbd/msdfs.c b/source3/smbd/msdfs.c index fffe44ab60..d0438b01af 100644 --- a/source3/smbd/msdfs.c +++ b/source3/smbd/msdfs.c @@ -251,8 +251,7 @@ BOOL is_msdfs_link(connection_struct* conn, char * path, if (S_ISLNK(sbufp->st_mode)) { /* open the link and read it */ - referral_len = SMB_VFS_READLINK(conn, path, referral, - sizeof(pstring)); + referral_len = SMB_VFS_READLINK(conn, path, referral, sizeof(pstring)-1); if (referral_len == -1) { DEBUG(0,("is_msdfs_link: Error reading msdfs link %s: %s\n", path, strerror(errno))); return False; -- cgit