qcap: Define O_CLOEXEC when needed
Bruno Jesus
00cpxxx at gmail.com
Mon Feb 20 17:01:35 CST 2017
On Mon, Feb 20, 2017 at 7:28 PM, André Hentschel <nerv at dawncrow.de> wrote:
> Signed-off-by: André Hentschel <nerv at dawncrow.de>
> ---
>
> https://bugs.winehq.org/show_bug.cgi?id=42478
>
> dlls/qcap/v4l.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/dlls/qcap/v4l.c b/dlls/qcap/v4l.c
> index d67df73..19c6f2e 100644
> --- a/dlls/qcap/v4l.c
> +++ b/dlls/qcap/v4l.c
> @@ -71,6 +71,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(qcap_v4l);
>
> #ifdef VIDIOCMCAPTURE
>
> +#ifndef O_CLOEXEC
> +#define O_CLOEXEC 2000000
> +#endif
Hi, comparing to my fcntl.h the value should be octal:
#define O_CLOEXEC 02000000 /* set close_on_exec */
But FreeBSD 10 defines like:
#define O_CLOEXEC 0x00100000
02000000 = 524288
0x00100000 = 1048576
So I guess it is better to define as zero or #ifdef it out.
More information about the wine-devel
mailing list