PVS-StudioWarnings

PVS-Studio warning V565 for GLG3D

Nov 13th, 2014
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.65 KB | None | 0 0
  1. void testTextInput() {
  2.   ...
  3.   try {
  4.     t.readNumber();
  5.     alwaysAssertM(false, "Incorrect parse");
  6.   } catch (....) {
  7.   }
  8.   ...
  9. }
  10.  
  11. alwaysAssertM is written in a wrong place. The string with alwaysAssertM should be inside catch.
  12.  
  13. This suspicious code was found in GLG3D project by PVS-Studio static code analyzer.
  14. Warning message is:
  15. V565 An empty exception handler. Silent suppression of exceptions can hide the presence of bugs in source code during testing. test ttextinput.cpp 495
  16.  
  17. PVS-Studio is a static analyzer for detecting bugs in the source code of applications written in C, C++, C++11, C++/CX. Site: http://www.viva64.com/en/pvs-studio/
Advertisement
Add Comment
Please, Sign In to add comment