[prev in list] [next in list] [prev in thread] [next in thread]
List: glibc-alpha
Subject: Re: [PATCH v2] linux: Make fdopendir fail with O_PATH (BZ 30373)
From: Paul Eggert <eggert () cs ! ucla ! edu>
Date: 2023-08-31 20:21:30
Message-ID: ce9beade-2773-493e-e524-0c77db98c2e5 () cs ! ucla ! edu
[Download RAW message or body]
On 2023-08-10 06:54, Adhemerval Zanella via Libc-alpha wrote:
> + /* Fail early for descriptors opened with O_PATH. */
> + if (__glibc_unlikely ((flags & O_PATH) == O_PATH))
> + {
> + __set_errno (EBADF);
> + return NULL;
> + }
Shouldn't this be (flags & O_PATH), not ((flags & O_PATH) == O_PATH)?
The latter suggests more complexity than there really is.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic