diff options
author | Rusty Russell <rusty@rustcorp.com.au> | 2012-06-18 22:30:27 +0930 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2012-06-19 05:38:06 +0200 |
commit | 5027f9cd02bf322498313a6b7aabd03fd510d725 (patch) | |
tree | 94d67ad070ec4039c4e90c029a771ecc4f9929b2 /source3/smbd/smb2_setinfo.c | |
parent | 1765c0f9baf16ff1c2f5f109fb31e411831f0945 (diff) | |
download | samba-5027f9cd02bf322498313a6b7aabd03fd510d725.tar.gz samba-5027f9cd02bf322498313a6b7aabd03fd510d725.tar.bz2 samba-5027f9cd02bf322498313a6b7aabd03fd510d725.zip |
ntdb: reduce race between creating file and getting open lock.
In tdb, we grab the open lock immediately after we open the file. In
ntdb, we usually did some work first. tdbtorture managed to get in
before the creator grabbed the lock:
testing with 3 processes, 5000 loops, seed=1338246020
ntdb:torture.ntdb:IO Error:ntdb_open: torture.ntdb is not a ntdb file
29023:torture.ntdb:db open failed
At cost of a little duplicated code, we can reduce the race.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'source3/smbd/smb2_setinfo.c')
0 files changed, 0 insertions, 0 deletions