PVS-StudioWarnings

PVS-Studio warning V557 for Virtualdub

Nov 19th, 2014
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.70 KB | None | 0 0
  1. struct ConvoluteFilterData {
  2.  long m[9];
  3.  long bias;
  4.  void *dyna_func;
  5.  DWORD dyna_size;
  6.  DWORD dyna_old_protect;
  7.  BOOL fClip;
  8. };
  9.  
  10. static unsigned long __fastcall do_conv(
  11.   unsigned long *data,
  12.   const ConvoluteFilterData *cfd,
  13.   long sflags, long pit)
  14. {
  15.   long rt0=cfd->m[9], gt0=cfd->m[9], bt0=cfd->m[9];
  16.   ...
  17. }
  18.  
  19. This suspicious code was found in Virtualdub project by PVS-Studio static code analyzer.
  20. Warning message is:
  21. V557 Array overrun is possible. The '9' index is pointing beyond array bound. VirtualDub f_convolute.cpp 73
  22.  
  23. 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