PVS-StudioWarnings

PVS-Studio warning V560 for windjview

Nov 20th, 2014
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.55 KB | None | 0 0
  1. inline bool IsValidChar(int c)
  2. {
  3.   return c == 0x9 || 0xA || c == 0xD ||
  4.          c >= 0x20 && c <= 0xD7FF ||
  5.          c >= 0xE000 && c <= 0xFFFD ||
  6.          c >= 0x10000 && c <= 0x10FFFF;
  7. }
  8.  
  9. This suspicious code was found in windjview project by PVS-Studio static code analyzer.
  10. Warning message is:
  11. V560 A part of conditional expression is always true: 0xA. WinDjView xmlparser.cpp 45
  12.  
  13. 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