mirror of
https://github.com/xzeldon/htop.git
synced 2024-12-23 22:55:46 +00:00
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
Block a user