off64_t, loff_t
Hi Michael,
This is related to:
https://lore.kernel.org/linux-man/CAKgNAkhuL9JRG_YhVG6Y-yjobDVAGjrUSdcQ4kV-4MABjZiwRQ@mail.gmail.com/
copy_file_range(2) says it uses 'loff_t':
$ man 2 copy_file_range \
Quoted 1 line
|sed -n '/SYNOPSIS/,/DESCRIPTION/{/copy_file_range/,/^$/p}';
ssize_t copy_file_range(int fd_in, loff_t *off_in,
int fd_out, loff_t *off_out, size_t len, unsigned int flags);
But glibc uses 'off64_t' AFAICS:
$ syscall='copy_file_range';
$ pattern="^[^ ]*ssize_t ${syscall}[ ]*(";
$ find glibc/ -name '*.h' \Quoted 3 lines
|xargs sed -n -e "/${pattern}/p" -e "/${pattern}/,/^$/p" \
|sed -n -e "/${pattern}/,/;/p" -e '/^$/p' \
|uniq;ssize_t copy_file_range (int __infd, __off64_t *__pinoff,
int __outfd, __off64_t *__poutoff, size_t __length, unsigned int __flags);
What would you do about it?sed -i 's/loff_t/off64_t/' man2/copy_file_range.2?
Thanks,
Alex
Signature · 3 lines
Alejandro Colomar Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/ http://www.alejandro-colomar.es/
Hi Alex,
Quoted 23 lines · Alejandro Colomar (man-pages)
Hi Michael,
This is related to:
https://lore.kernel.org/linux-man/CAKgNAkhuL9JRG_YhVG6Y-yjobDVAGjrUSdcQ4kV-4MABjZiwRQ@mail.gmail.com/
copy_file_range(2)says it uses 'loff_t':$ man 2 copy_file_range \Quoted 1 line
|sed -n '/SYNOPSIS/,/DESCRIPTION/{/copy_file_range/,/^$/p}';
ssize_tcopy_file_range(intfd_in,loff_t*off_in,
intfd_out,loff_t*off_out,size_tlen, unsigned int flags);But glibc uses '
off64_t' AFAICS:$ syscall='copy_file_range'; $ pattern="^[^ ]*ssize_t ${syscall}[ ]*("; $ find glibc/ -name '*.h' \Quoted 3 lines
|xargs sed -n -e "/${pattern}/p" -e "/${pattern}/,/^$/p" \ |sed -n -e "/${pattern}/,/;/p" -e '/^$/p' \ |uniq;
Quoted 7 lines
ssize_tcopy_file_range(int__infd,__off64_t*__pinoff,int __outfd, __off64_t *__poutoff, size_t __length, unsigned int __flags);What would you do about it?
sed -i 's/loff_t/off64_t/' man2/copy_file_range.2?
Yes, I think that change would be appropriate.
Thanks,
Michael
Signature · 3 lines
Michael Kerrisk Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/ Linux/UNIX System Programming Training: http://man7.org/training/