...
TR 24731-1 introduces the new type errno_t
that is defined to be type int
in <errno.h>
and elsewhere. Many of the functions defined in TR 24731-1 return values of this type. As a matter of programming style, errno_t
should be used as the type of something that deals only with the values that might be found in errno
. For example, a function that returns the value of errno
should be declared as having the return type errno_t
.
This recommendation depends on TR 24731-1 and advocates using errno_t
in new code where appropriate.
Non-Compliant Code Example
...