Skip to content

Commit

Permalink
[Tests] Fix typo in FileCopy test
Browse files Browse the repository at this point in the history
Caught by a warning in Clang:

tests/XrdClTests/FileCopyTest.cc:400:62: warning: variable 'st'
is uninitialized when used within its own initialization [-Wuninitialized]
    CPPUNIT_ASSERT_XRDST( status.status == XrdCl::stError && st.code == XrdCl::errNotFound );
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tests/XrdClTests/../common/CppUnitXrdHelpers.hh:36:28:
 note: expanded from macro 'CPPUNIT_ASSERT_XRDST'

  XrdCl::XRootDStatus st = x;
  • Loading branch information
amadio committed Apr 13, 2023
1 parent 242ca56 commit c20746d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/XrdClTests/FileCopyTest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ void FileCopyTest::CopyTestFunc( bool thirdParty )
CPPUNIT_ASSERT_XRDST_NOTOK( process12.Run(0), XrdCl::errCheckSumError );
XrdCl::StatInfo *info = 0;
XrdCl::XRootDStatus status = fs.Stat( targetPath, info );
CPPUNIT_ASSERT_XRDST( status.status == XrdCl::stError && st.code == XrdCl::errNotFound );
CPPUNIT_ASSERT_XRDST( status.status == XrdCl::stError && status.code == XrdCl::errNotFound );
properties.Clear();

//--------------------------------------------------------------------------
Expand Down

0 comments on commit c20746d

Please sign in to comment.