summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
authorRaghavendra Bhat <raghavendrabhat@gluster.com>2010-04-27 03:46:39 +0000
committerAnand V. Avati <avati@dev.gluster.com>2010-04-27 02:38:10 -0700
commit55d332f5eca51ee4820ecd62af1cdb2a24ad100e (patch)
tree990e514c1c949d41cad4ba2eb1813f078723d443 /xlators
parent81d53a0f5d09afed172ceb93061156c8910fa5d1 (diff)
Set op_ret to -1 when open fails in posix_create
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 825 (when create() races both return success) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=825
Diffstat (limited to 'xlators')
-rw-r--r--xlators/storage/posix/src/posix.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/xlators/storage/posix/src/posix.c b/xlators/storage/posix/src/posix.c
index 5ed3e5dc631..c22517f9ecd 100644
--- a/xlators/storage/posix/src/posix.c
+++ b/xlators/storage/posix/src/posix.c
@@ -2074,6 +2074,7 @@ posix_create (call_frame_t *frame, xlator_t *this,
if (_fd == -1) {
op_errno = errno;
+ op_ret = -1;
gf_log (this->name, GF_LOG_ERROR,
"open on %s failed: %s", loc->path,
strerror (op_errno));