]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mds: fix O_APPEND file mode calculation
authorSage Weil <sage@newdream.net>
Tue, 19 Jul 2011 15:33:29 +0000 (08:33 -0700)
committerSage Weil <sage@newdream.net>
Tue, 19 Jul 2011 15:33:37 +0000 (08:33 -0700)
commit650f9f315bed2417394b7f43290b88701f933b89
treeb1b2f6fca89680c458283344f29e32e1d9030620
parent59a8e65e4743f1331c4897c2800e7fcc0c234425
mds: fix O_APPEND file mode calculation

Currently

  fd = open("aaa",O_RDWR|O_CREAT|O_APPEND,0666);

gives us fmode of 1 instead of 3.  We should only infer O_WRONLY if no
other mode is explicitly specified.

Reported-by: Fyodor Ustinov <ufm@ufm.su>
Signed-off-by: Sage Weil <sage@newdream.net>
src/include/ceph_fs.cc