syncfs returns int (or long?)
In man 2 syncfs (version 2011-09-07, also in the website) it is declared as:
void syncfs(int fd);
but then is said:
RETURN VALUE
syncfs() returns 0 on success; on error, it returns -1 and sets errno to indicate the error.
so it cannot be void. I get
piccardi@monk:/usr/src/linux-source-3.1$ grep -r syncfs include/* include/asm-generic/unistd.h:#define __NR_syncfs 267 include/asm-generic/unistd.h:__SYSCALL(__NR_syncfs, sys_syncfs) include/linux/syscalls.h:asmlinkage long sys_syncfs(int fd);
So it seems to be at least long.
Simone
Signature · 8 lines
Simone Piccardi - KeyID:2A972F9D - JabberID:[email protected] http://piccardi.gnulinux.it - http://www.fountainpen.it Prima ti ignorano, poi ti deridono, poi ti combattono. Poi vinci. M. K. Ghandi -- To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hello SImone,
Quoted 10 lines · Simone Piccardi
In man 2 syncfs (version 2011-09-07, also in the website) it is declared as:
void syncfs(int fd);
but then is said:
RETURN VALUE
syncfs()returns 0 on success; on error, it returns -1 and sets errno to indicate the error.
Quoted 8 lines
so it cannot be void. I get
piccardi@monk:/usr/src/linux-source-3.1$ grep -r syncfs include/* include/asm-generic/unistd.h:#define __NR_syncfs 267 include/asm-generic/unistd.h:__SYSCALL(__NR_syncfs, sys_syncfs) include/linux/syscalls.h:asmlinkage long sys_syncfs(int fd);So it seems to be at least long.
Thanks for the report! In glibc, the prototype is "int", so for man-pages-3.36 I've changed it to "int".
Thanks,
Michael
Signature · 7 lines
Michael Kerrisk Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/ Author of "The Linux Programming Interface"; http://man7.org/tlpi/ -- To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html