From 7a958026f3526468a0c949fcceb116b33e29b903 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Wed, 19 Mar 2014 16:09:15 +0000 Subject: coverity#984119 Uninitialized pointer field Change-Id: I6bbb181b892f22d05be76fc75506d94543eb7ee7 --- sal/qa/osl/file/osl_File.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'sal/qa') diff --git a/sal/qa/osl/file/osl_File.cxx b/sal/qa/osl/file/osl_File.cxx index 63b9bcbe714a..525630368fc4 100644 --- a/sal/qa/osl/file/osl_File.cxx +++ b/sal/qa/osl/file/osl_File.cxx @@ -2460,6 +2460,11 @@ namespace osl_FileStatus ::osl::DirectoryItem rItem_file, rItem_link; public: + isValid() + : pDir(NULL) + { + } + // initialization void setUp() { @@ -2477,8 +2482,8 @@ namespace osl_FileStatus void tearDown() { - ::osl::FileBase::RC nError1 = pDir->close(); - delete pDir; + ::osl::FileBase::RC nError1 = pDir->close(); + delete pDir; CPPUNIT_ASSERT_MESSAGE( errorToStr(nError1).getStr(), ::osl::FileBase::E_None == nError1 ); // remove the tempfile in $TEMP/tmpdir/tmpname. -- cgit