diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-07-18 11:16:11 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-07-19 09:43:43 +0200 |
commit | 311d835a4a02782284bcdaa6c7334f6a76bb86f5 (patch) | |
tree | c1d6a3859b1be3720e4e1461e8c9b54d3528ef3e /svtools | |
parent | ff17310476041ab44cd312731f83fa7891bac599 (diff) |
cid#1448488 Unchecked return value
Change-Id: If42c4f2215057120774b4ad7e2755e4e861bd828
Reviewed-on: https://gerrit.libreoffice.org/75898
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/misc/filechangedchecker.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/svtools/source/misc/filechangedchecker.cxx b/svtools/source/misc/filechangedchecker.cxx index c1e67a0fe1f0..09e24c3fafb1 100644 --- a/svtools/source/misc/filechangedchecker.cxx +++ b/svtools/source/misc/filechangedchecker.cxx @@ -45,12 +45,13 @@ bool FileChangedChecker::getCurrentModTime(TimeValue& o_rValue) const { // Need a Directory item to fetch file status osl::DirectoryItem aItem; - osl::DirectoryItem::get(mFileName, aItem); + if (osl::FileBase::E_None != osl::DirectoryItem::get(mFileName, aItem)) + return false; // Retrieve the status - we are only interested in last File // Modified time osl::FileStatus aStatus( osl_FileStatus_Mask_ModifyTime ); - if( osl::FileBase::E_None != aItem.getFileStatus(aStatus) ) + if (osl::FileBase::E_None != aItem.getFileStatus(aStatus)) return false; o_rValue = aStatus.getModifyTime(); |