mirror of https://github.com/xzeldon/htop.git
Add DeepCode inline suppression
commsize is bounded by the allocated length passed in by commLen, saved into commLenIn
This commit is contained in:
parent
f4bb50294a
commit
594409f299
|
@ -261,6 +261,7 @@ static bool LinuxProcessList_readStatFile(Process *process, const char* dirname,
|
|||
if (!end) return false;
|
||||
|
||||
int commsize = MINIMUM(end - location, commLenIn - 1);
|
||||
// deepcode ignore BufferOverflow: commsize is bounded by the allocated length passed in by commLen, saved into commLenIn
|
||||
memcpy(command, location, commsize);
|
||||
command[commsize] = '\0';
|
||||
*commLen = commsize;
|
||||
|
|
Loading…
Reference in New Issue