aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2013-04-28 14:15:34 +0200
committerPieter Wuille <pieter.wuille@gmail.com>2013-04-28 14:15:34 +0200
commit551b367f19dce1951362a1f9911004e583732376 (patch)
tree5da925a0ee0e72ca9a48e918c23acdd6c1a40720
parent20d6f2013b6629566b3fe1b5b03800fecac25e96 (diff)
Allow files to be opened for reading multiple times
-rw-r--r--src/leveldb/util/env_win.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/leveldb/util/env_win.cc b/src/leveldb/util/env_win.cc
index 4730192bf8..ef2ecae830 100644
--- a/src/leveldb/util/env_win.cc
+++ b/src/leveldb/util/env_win.cc
@@ -420,7 +420,7 @@ BOOL Win32RandomAccessFile::_Init( LPCWSTR path )
{
BOOL bRet = FALSE;
if(!_hFile)
- _hFile = ::CreateFileW(path,GENERIC_READ,0,NULL,OPEN_EXISTING,
+ _hFile = ::CreateFileW(path,GENERIC_READ,FILE_SHARE_READ,NULL,OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL | FILE_FLAG_RANDOM_ACCESS,NULL);
if(!_hFile || _hFile == INVALID_HANDLE_VALUE )
_hFile = NULL;