From: Alejandro Colomar <colomar.6.4.3@gmail.com>
To: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
Cc: linux-man@vger.kernel.org,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"libc-alpha@sourceware.org" <libc-alpha@sourceware.org>
Subject: Re: [PATCH] getdents.2: Use 'ssize_t' instead of 'int'
Date: Thu, 29 Oct 2020 12:02:44 +0100 [thread overview]
Message-ID: <1195fda6-4de3-09fc-8653-42655d7e2b76@gmail.com> (raw)
In-Reply-To: <ed5937c4-a590-1735-b716-0894657ff8fc@gmail.com>
[[ CC += linux-kernel, libc-alpha ]]
Hi Michael,
On 2020-10-29 08:13, Michael Kerrisk (man-pages) wrote:
> Hi Alex,
>
> On 10/28/20 11:11 PM, Alejandro Colomar wrote:
>> The glibc wrapper for getdents64() uses ssize_t.
>
> It also changed the types for the arguments, so those need to be
> fixed too.
I saw that, but I sent an email to glibc asking if it was a bug.
I'll hold this patch, and I'll CC this list in that other thread.
>
>> And let's use it also for getdents().
>
> I actually think we should *not* change that. So long as their is
> no wrapper, we should show pretty much what the ABI exposes. (That
> makes me think that the return type should really be long; see
> what you think about DEFINE_SYSCALL3 in the kernel sources.)
Agreed; then getdents() (and all syscalls without a wrapper)
should use 'long', as you said.
BTW: My mind explodes when I try to read through SYSCALL_DEFINEx :)
>
> And you added an include for <sys/types.h>. I'm not sure
> whether that's needed, but it should be explained in the
> commit message.
Agreed.
I should be able to check if it's needed, in ssize_t(3) :p
... Actually it's not needed (<stdio.h> already provides it).
Thanks,
Alex
next prev parent reply other threads:[~2020-10-29 11:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-28 22:11 [PATCH] getdents.2: Use 'ssize_t' instead of 'int' Alejandro Colomar
2020-10-29 7:13 ` Michael Kerrisk (man-pages)
2020-10-29 11:02 ` Alejandro Colomar [this message]
2020-10-29 13:42 ` [PATCH v2] getdents.2: Use appropriate types Alejandro Colomar
2020-10-29 13:55 ` Michael Kerrisk (man-pages)
2020-10-29 14:10 ` [PATCH v3] " Alejandro Colomar
2020-10-29 19:54 ` Michael Kerrisk (man-pages)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1195fda6-4de3-09fc-8653-42655d7e2b76@gmail.com \
--to=colomar.6.4.3@gmail.com \
--cc=libc-alpha@sourceware.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-man@vger.kernel.org \
--cc=mtk.manpages@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox