diff options
author | Anand Avati <avati@gluster.com> | 2009-09-24 08:31:10 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2009-09-24 07:13:41 -0700 |
commit | 1ed903641a297aaa16d212243eb17c8899d7969b (patch) | |
tree | 99f023a9399ee86e40c944c5740eb95120549f7b | |
parent | bad9a77c646bc286feecba4d62e036504993175d (diff) |
write-behind: check for NULL file pointer in flush callback
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 260 (ls on booster VMP results in error: "File descriptor in bad state")
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=260
-rw-r--r-- | xlators/performance/write-behind/src/write-behind.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/performance/write-behind/src/write-behind.c b/xlators/performance/write-behind/src/write-behind.c index c78efe4323e..a40612563c1 100644 --- a/xlators/performance/write-behind/src/write-behind.c +++ b/xlators/performance/write-behind/src/write-behind.c @@ -1663,7 +1663,8 @@ wb_ffr_cbk (call_frame_t *frame, void *cookie, xlator_t *this, int32_t op_ret, conf = this->private; local = frame->local; - file = local->file; + if (local) + file = local->file; if (file == NULL) { unwind = 1; |