[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-devel
Subject: Re: ntdll: Fix build on systems without ENODATA (was: [PATCH] ntdll: Complete error case in get_init
From: "Erich E. Hoover" <erich.e.hoover () gmail ! com>
Date: 2022-10-19 21:28:26
Message-ID: CAEU2+vqXdjSww4Dno2=+Z_dkH3S0jMg97T6thnB9vMATaRrtew () mail ! gmail ! com
[Download RAW message or body]
On Wed, Oct 19, 2022 at 3:05 PM Gerald Pfeifer <gerald@pfeifer.com> wrote:
>
> On Wed, 19 Oct 2022, Erich E. Hoover wrote:
> >> https://gitlab.winehq.org/wine/wine/-/merge_requests/1097
> > It looks like this just got merged. Gerald, would you check and see
> > if ENOATTR is defined on your system?
>
> I checked, and FreeBSD (12 and 14, so current and future versions) both
> define ENOATTR guarded by #ifndef _POSIX_SOURCE, so generally available.
>
> > This commit removes the compile warning
>
> It actually was hard build error.
Yes, sorry - I misspoke.
> > but you're going to get a lot of unnecessary console warnings
> > ("attribute does not exist" is not an error here).
>
> Is it possible Alexandre's adjusted version of my submission avoids this?
> ...
No. If the filesystem supports extended attributes (!ENOTSUP) then
you will get an error if there aren't any xattr for the file. I
suspect that we either want:
===
#ifdef ENODATA
if (errno == ENODATA) return ret;
#endif
#ifdef ENOATTR
if (errno == ENOATTR) return ret;
#endif
===
Or we want to do something like this:
===
#ifndef ENOATTR
#define ENOATTR ENODATA
#endif
===
and then check against ENOATTR instead (little bit of research says
that platforms that define both use ENOATTR in this case).
Best,
Erich
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic