Secure Programming for Linux and Unix HOWTO
Prev | Chapter 8. Carefully Call Out to Other Resources | Next

# 8.5. Check All System Call Returns

Every system call that can return an error condition must have that error condition checked. One reason is that nearly all system calls require limited system resources, and users can often affect resources in a variety of ways. Setuid/setgid programs can have limits set on them through calls such as setrlimit(3) and nice(2). External users of server programs and CGI scripts may be able to cause resource exhaustion simply by making a large number of simultaneous requests. If the error cannot be handled gracefully, then fail safe as discussed earlier.

Prev | Home | Next
Call Only Interfaces Intended for Programmers | Up | Avoid Using vfork(2)