Skip to content

Commit

Permalink
Check bufio.(*Scanner).Err()
Browse files Browse the repository at this point in the history
  • Loading branch information
tklauser committed Dec 1, 2023
1 parent 73ea1b3 commit fd2d5e3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions sysconf_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@ func getNprocsProcStat() (int64, error) {
break
}
}
if err := s.Err(); err != nil {
return -1, err
}
return count, nil
}

Expand Down

0 comments on commit fd2d5e3

Please sign in to comment.