partio
partio copied to clipboard
resource leak in ZIP.cpp
I found the leak with the static code checking tool cppcheck. There are other minor bugs as well, but this one is the biggest. The leak is found in file master/src/lib/io/ZIP.cpp on line 511
if(read_start<=0){std::cerr<<"ZIP: Invalid read buffer size"<<std::endl;return false;}
it should be:
if(read_start<=0){std::cerr<<"ZIP: Invalid read buffer size"<<std::endl;delete [] buf;return false;}