cpulimit icon indicating copy to clipboard operation
cpulimit copied to clipboard

Wrong logic in matching the process name

Open HiGarfield opened this issue 3 years ago • 0 comments

https://github.com/opsengine/cpulimit/blob/f4d2682804931e7aea02a869137344bb5452a3cd/src/process_group.c#L64

"strncmp" is not a correct way.

For example, if we use "cpulimit -e abc -l 30", then the process with the name "abcd" may be limited.

The correct way is to use "strcmp".

HiGarfield avatar Apr 18 '22 09:04 HiGarfield