From 00f6baa15ae29e04f8d298dd5bbb81719cc912a7 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 17 Nov 2004 21:05:47 +0000 Subject: r3823: Fix bug reported by Tom Dickson with follow symlinks = no reporting an incorrect error when it should be access denied. Jeremy. (This used to be commit 5a103f4abff0503740822c8ed75d9102ee51e8f0) --- source3/smbd/vfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source3/smbd/vfs.c') diff --git a/source3/smbd/vfs.c b/source3/smbd/vfs.c index f30a555900..10599c50a1 100644 --- a/source3/smbd/vfs.c +++ b/source3/smbd/vfs.c @@ -897,7 +897,8 @@ BOOL reduce_name(connection_struct *conn, const pstring fname) } default: DEBUG(1,("reduce_name: couldn't get realpath for %s\n", fname)); - errno = saved_errno; + /* Don't restore the saved errno. We need to return the error that + realpath caused here as it was not one of the cases we handle. JRA. */ return False; } } -- cgit