diff options
author | Raghavendra G <raghavendra@gluster.com> | 2010-05-04 02:27:04 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2010-05-04 03:32:10 -0700 |
commit | ef105a25b021bb8be5d2cbeae868da9d9288e77a (patch) | |
tree | 261837effa0df556ea226afd4794a086409a7ce4 /glusterfsd | |
parent | cdb67095fd35bc647098981e9e2687226196a645 (diff) |
performance/read-ahead: don't set ra_file in fd->ctx unless all memebers of ra_file is initialized
- If ptr to ra_file is set in fd->ctx even before initializing all its
members, A race condition may occur b/w a thread executing ra_fstat,
ra_readv etc (where all files open on the same inode are flushed) and
the thread doing initialization of ra_file (in ra_open_cbk or
ra_create_cbk). Because of this race-condition, flush_region might be
called on an uninitialized ra_file, thereby causing crash.
Signed-off-by: Raghavendra G <raghavendra@gluster.com>
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 868 (crash in ra_fstat)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=868
Diffstat (limited to 'glusterfsd')
0 files changed, 0 insertions, 0 deletions