diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:28:53 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:32:00 +0100 |
commit | 42e2262cdd05718a3286f813da6f53805846da02 (patch) | |
tree | 12caa143a9a41dabbe097377d9ef3aa7919c5100 /writerperfect/qa | |
parent | 0a1c17a30cd98892e0e60b512200ac07ff1ab320 (diff) |
loplugin:nullptr (automatic rewrite)
Change-Id: Ie4d4ce386f2810244fb97bf909870a839256971d
Diffstat (limited to 'writerperfect/qa')
-rw-r--r-- | writerperfect/qa/unit/DirectoryStreamTest.cxx | 2 | ||||
-rw-r--r-- | writerperfect/qa/unit/WPXSvStreamTest.cxx | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/writerperfect/qa/unit/DirectoryStreamTest.cxx b/writerperfect/qa/unit/DirectoryStreamTest.cxx index 6ab8d384e20c..effedf8c5e4e 100644 --- a/writerperfect/qa/unit/DirectoryStreamTest.cxx +++ b/writerperfect/qa/unit/DirectoryStreamTest.cxx @@ -106,7 +106,7 @@ void lcl_testDataOperations(RVNGInputStream &rStream) CPPUNIT_ASSERT_EQUAL(-1, rStream.seek(0, librevenge::RVNG_SEEK_CUR)); unsigned long numBytesRead = 0; - CPPUNIT_ASSERT(0 == rStream.read(1, numBytesRead)); + CPPUNIT_ASSERT(nullptr == rStream.read(1, numBytesRead)); CPPUNIT_ASSERT_EQUAL(0UL, numBytesRead); } diff --git a/writerperfect/qa/unit/WPXSvStreamTest.cxx b/writerperfect/qa/unit/WPXSvStreamTest.cxx index 3723d483f357..2ac9f28af307 100644 --- a/writerperfect/qa/unit/WPXSvStreamTest.cxx +++ b/writerperfect/qa/unit/WPXSvStreamTest.cxx @@ -122,7 +122,7 @@ void WPXSvStreamTest::testRead() const unsigned long nLen = sizeof aText; unsigned long nReadBytes = 0; - const unsigned char *pData = 0; + const unsigned char *pData = nullptr; const unsigned char *const pTextOrig = reinterpret_cast<const unsigned char *>(aText); const unsigned char *pText = pTextOrig; @@ -174,7 +174,7 @@ void WPXSvStreamTest::testRead() pData = pInput->read(0UL, nReadBytes); CPPUNIT_ASSERT_EQUAL(0UL, nReadBytes); CPPUNIT_ASSERT_EQUAL(0L, pInput->tell()); - CPPUNIT_ASSERT_EQUAL(pData, static_cast<const unsigned char *>(0)); + CPPUNIT_ASSERT_EQUAL(pData, static_cast<const unsigned char *>(nullptr)); CPPUNIT_ASSERT(!pInput->isEnd()); } @@ -340,9 +340,9 @@ void WPXSvStreamTest::testStructured() CPPUNIT_ASSERT(!pInput->isStructured()); CPPUNIT_ASSERT(0 == pInput->subStreamCount()); CPPUNIT_ASSERT(!pInput->existsSubStream("foo")); - CPPUNIT_ASSERT(0 == pInput->getSubStreamByName("foo")); - CPPUNIT_ASSERT(0 == pInput->getSubStreamById(42)); - CPPUNIT_ASSERT(0 == pInput->subStreamName(42)); + CPPUNIT_ASSERT(nullptr == pInput->getSubStreamByName("foo")); + CPPUNIT_ASSERT(nullptr == pInput->getSubStreamById(42)); + CPPUNIT_ASSERT(nullptr == pInput->subStreamName(42)); } } |