diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2008-08-27 06:51:39 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2008-08-27 06:51:39 +0000 |
commit | e6cd9608cd609a85a8fe7c0592a8c797b142afb8 (patch) | |
tree | 21ab2df34576e638219b28ab51f5019d28d34918 /ucb | |
parent | 6459533759d1d59647fabc99f31a9b8262c4c618 (diff) |
INTEGRATION: CWS mav37_DEV300 (1.97.22); FILE MERGED
2008/08/14 11:21:11 mav 1.97.22.1: #i92735# do not lock file while inserting with no removing
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/ucp/file/shell.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/ucb/source/ucp/file/shell.cxx b/ucb/source/ucp/file/shell.cxx index cf0115ec66..293f2c571d 100644 --- a/ucb/source/ucp/file/shell.cxx +++ b/ucb/source/ucp/file/shell.cxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: shell.cxx,v $ - * $Revision: 1.97 $ + * $Revision: 1.98 $ * * This file is part of OpenOffice.org. * @@ -1810,7 +1810,7 @@ shell::write( sal_Int32 CommandId, } else { - err = aFile.open( OpenFlag_Write ); + err = aFile.open( OpenFlag_Read | OpenFlag_NoLock ); if( err == osl::FileBase::E_None ) // The file exists and shall not be overwritten { installError( CommandId, @@ -1821,10 +1821,13 @@ shell::write( sal_Int32 CommandId, return sal_False; } - err = aFile.open( OpenFlag_Write | OpenFlag_Create ); + // as a temporary solution the creation does not lock the file at all + // in future it should be possible to create the file without lock explicitly + err = aFile.open( OpenFlag_Write | OpenFlag_Create | OpenFlag_NoLock ); if( err != osl::FileBase::E_None ) { + aFile.close(); installError( CommandId, TASKHANDLING_NO_OPEN_FILE_FOR_WRITE, err ); |