summaryrefslogtreecommitdiff
path: root/basic/qa
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-05-19 11:25:32 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-05-19 12:53:34 +0200
commit2e51afc77c0800dda6c09bb645d8962ae125b2ba (patch)
tree087dc79cce1eaeedb9556be0953bdda2e8954560 /basic/qa
parent575b457d728531a1cfff95d2eea1887e09d79009 (diff)
loplugin:comparisonwithconstant in basic
Change-Id: Ie34a17d2fb465ffbe675ba4e99917d23959f1fb5 Reviewed-on: https://gerrit.libreoffice.org/37809 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basic/qa')
-rw-r--r--basic/qa/cppunit/basic_coverage.cxx4
-rw-r--r--basic/qa/cppunit/basictest.cxx6
2 files changed, 5 insertions, 5 deletions
diff --git a/basic/qa/cppunit/basic_coverage.cxx b/basic/qa/cppunit/basic_coverage.cxx
index 1f336b482819..bee658a586d5 100644
--- a/basic/qa/cppunit/basic_coverage.cxx
+++ b/basic/qa/cppunit/basic_coverage.cxx
@@ -99,7 +99,7 @@ std::vector< OUString > Coverage::get_subdirnames( const OUString& sDirName )
osl::DirectoryItem aItem;
osl::FileStatus aFileStatus(osl_FileStatus_Mask_FileURL|osl_FileStatus_Mask_Type);
- if(osl::FileBase::E_None == aDir.open())
+ if(aDir.open() == osl::FileBase::E_None)
{
while (aDir.getNextItem(aItem) == osl::FileBase::E_None)
{
@@ -116,7 +116,7 @@ void Coverage::process_directory(const OUString& sDirName)
osl::DirectoryItem aItem;
osl::FileStatus aFileStatus(osl_FileStatus_Mask_FileURL|osl_FileStatus_Mask_Type);
- if(osl::FileBase::E_None == aDir.open())
+ if(aDir.open() == osl::FileBase::E_None)
{
while (aDir.getNextItem(aItem) == osl::FileBase::E_None)
{
diff --git a/basic/qa/cppunit/basictest.cxx b/basic/qa/cppunit/basictest.cxx
index ebd97d8c7ef4..bedd89e5dacf 100644
--- a/basic/qa/cppunit/basictest.cxx
+++ b/basic/qa/cppunit/basictest.cxx
@@ -49,15 +49,15 @@ void MacroSnippet::LoadSourceFromFile( const OUString& sMacroFileURL )
fprintf(stderr,"loadSource opening macro file %s\n", OUStringToOString( sMacroFileURL, RTL_TEXTENCODING_UTF8 ).getStr() );
osl::File aFile(sMacroFileURL);
- if(osl::FileBase::E_None == aFile.open(osl_File_OpenFlag_Read))
+ if(aFile.open(osl_File_OpenFlag_Read) == osl::FileBase::E_None)
{
sal_uInt64 size;
sal_uInt64 size_read;
- if(osl::FileBase::E_None == aFile.getSize(size))
+ if(aFile.getSize(size) == osl::FileBase::E_None)
{
void* buffer = calloc(1, size+1);
CPPUNIT_ASSERT(buffer);
- if(osl::FileBase::E_None == aFile.read( buffer, size, size_read))
+ if(aFile.read( buffer, size, size_read) == osl::FileBase::E_None)
{
if(size == size_read)
{