From f2a9ce7abacc8749589d0b931ca155d2c7578774 Mon Sep 17 00:00:00 2001 From: Vikas Gorur Date: Thu, 17 Mar 2011 19:08:49 +0000 Subject: nfs: Remove redundant and erroneous check for create mode EXCLUSIVE. nfs3.c/nfs3_create_common: The if condition checks for create mode being EXCLUSIVE. However, when create mode is EXCLUSIVE, this function never gets called (nfs3_create_exclusive is called). Also, instead of checking, it actually sets the value of createmode (= instead of ==). Signed-off-by: Vikas Gorur Signed-off-by: Vijay Bellur BUG: 2553 (NFS file create with Mac client and UNCHECKED mode returns "Operation not permitted") URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2553 --- xlators/nfs/server/src/nfs3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xlators/nfs/server/src/nfs3.c b/xlators/nfs/server/src/nfs3.c index e23d4ad75f0..f60a1e6c81e 100644 --- a/xlators/nfs/server/src/nfs3.c +++ b/xlators/nfs/server/src/nfs3.c @@ -2361,7 +2361,7 @@ nfs3_create_common (nfs3_call_state_t *cs) if (!cs) return ret; - if ((cs->createmode == UNCHECKED) || (cs->createmode = EXCLUSIVE)) + if (cs->createmode == UNCHECKED) flags = O_RDWR; else if (cs->createmode == GUARDED) flags = (O_RDWR | O_EXCL); -- cgit