Good evening Quoting part of the syscall man page: RETURN VALUE The return value is defined by the system call being invoked. In gen‐ eral, a 0 return value indicates success. A -1 return value indicates an error, and an error code is stored in errno.The last sentence doesn't quite sound right in English, and different from other man pages eg closedir. I would propose updating it to be :-
"On error, -1 is returned, and errno is set appropriately" Cheers Jonny