// LCOV_EXCL_STOP 5: fopen error case
}
perf_lines = 0;
- while (fgets(buf, sizeof(buf), rfd) > 0) {
+ while (fgets(buf, sizeof(buf), rfd) != NULL) {
if (perf_lines >= PERF_MAX_LINES) {
break;
}
// LCOV_EXCL_STOP 5: kill error case
}
} else {
- while (fgets(buf, sizeof(buf), stdin) > 0) {
+ while (fgets(buf, sizeof(buf), stdin) != NULL) {
// Save ProcessName and Process ID to exec perf
if (logLine >= 2 && perfNum < PERF_MAX_PROCS) {
buf2[0] = 0;
}
// LCOV_EXCL_STOP
} else {
- while (fgets(buf, sizeof(buf), stdin) > 0) {
+ while (fgets(buf, sizeof(buf), stdin) != NULL) {
if (logLine == 0) {
if (buf[0] != 'C') {
continue;