diff options
author | Kurt Zenker <kz@openoffice.org> | 2008-05-21 07:24:47 +0000 |
---|---|---|
committer | Kurt Zenker <kz@openoffice.org> | 2008-05-21 07:24:47 +0000 |
commit | 56cf44fd0e179bd73e412959d7b3473c67005de7 (patch) | |
tree | 284d74a9d8b2bf724266a43922962e28ecace76e /jvmfwk/source | |
parent | 7c8c2ed0d561432f7f93b3ecfc918c29ea37d13b (diff) |
INTEGRATION: CWS jl98_DEV300 (1.19.14); FILE MERGED
2008/05/02 09:20:24 jl 1.19.14.1: #i85109# when UNO_JAVA_JFW_INSTALL_DATA is used and the settings file has expired then it is not deleted as before but instead its size is set to zero
Diffstat (limited to 'jvmfwk/source')
-rw-r--r-- | jvmfwk/source/elements.cxx | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/jvmfwk/source/elements.cxx b/jvmfwk/source/elements.cxx index 25204ee283c9..0677398018da 100644 --- a/jvmfwk/source/elements.cxx +++ b/jvmfwk/source/elements.cxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: elements.cxx,v $ - * $Revision: 1.21 $ + * $Revision: 1.22 $ * * This file is part of OpenOffice.org. * @@ -769,9 +769,12 @@ jfw::FileStatus NodeJava::checkSettingsFileStatus() const fprintf(stderr, "[Java framework] Deleting settings file at \n%s\n", s.getStr()); #endif //delete file - File::RC rc_rem = File::remove(sURL); - if (File::E_None == rc_rem) - ret = FILE_DOES_NOT_EXIST; +// File::RC rc_rem = File::remove(sURL); + File f(sURL); + if (File::E_None == f.open(OpenFlag_Write | OpenFlag_Read) + && File::E_None == f.setPos(0, 0) + && File::E_None == f.setSize(0)) + ret = FILE_DOES_NOT_EXIST; else ret = FILE_INVALID; } |