Re: open_safer on amd64

2009-05-20 Thread Ben Pfaff
Eric Blake writes: > In earlier versions of POSIX, the intent was that mode_t could > be narrower than int, and that all programmers had to use only symbolic > constants in that argument. But POSIX 2008 changed its stance by adding > these words: > > The header shall define the following symbol

Re: open_safer on amd64

2009-05-20 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Bruno Haible on 5/20/2009 5:08 PM: > Sergey Poznyakoff wrote: >> When trying to compile open-safer.c on amd64 I get: >> >> open-safer.c: In function 'open_safer': >> open-safer.c:46: warning: 'mode_t' is promoted to 'int' when passed throu

Re: open_safer on amd64

2009-05-20 Thread Bruno Haible
Sergey Poznyakoff wrote: > When trying to compile open-safer.c on amd64 I get: > > open-safer.c: In function 'open_safer': > open-safer.c:46: warning: 'mode_t' is promoted to 'int' when passed through > '...' > open-safer.c:46: warning: (so you should pass 'int' not 'mode_t' to 'va_arg') > open-s

Re: Compiler error of m4-1.4.13 on AIX using xlc

2009-05-20 Thread Bruno Haible
Eric Blake asked: > > BTW: The xlC-compiler (more: it's header files) on AIX supports a define > > _LINUX_SOURCE_COMPAT which enables some linux compatibility behaviour (e.g. > > malloc(0) returns a pointer to 0 bytes memory, not just NULL). > > Should we be adding that to the list of pre-defined

open_safer on amd64

2009-05-20 Thread Sergey Poznyakoff
Hello, When trying to compile open-safer.c on amd64 I get: open-safer.c: In function 'open_safer': open-safer.c:46: warning: 'mode_t' is promoted to 'int' when passed through '...' open-safer.c:46: warning: (so you should pass 'int' not 'mode_t' to 'va_arg') open-safer.c:46: note: if this code is

Re: lib/dirent.in.h fails on AIX

2009-05-20 Thread Eric Blake
Eric Blake byu.net> writes: > What do you think of this patch? > > From: Eric Blake byu.net> > Date: Wed, 20 May 2009 14:45:07 -0600 > Subject: [PATCH] Another try at making math.h work for AIX xlc. > > * m4/include_next.m4: Avoid redundant m4_quote. > (gl_CHECK_NEXT_HEADERS): Also define > NE

Re: lib/dirent.in.h fails on AIX

2009-05-20 Thread Eric Blake
Bruno Haible clisp.org> writes: > > I have no idea why: > > #include > > behaves differently than: > > #include "///usr/vac/include/math.h" > > You'd figure with the #include_next in /usr/vac/include/math.h > > the behavior would be the same. However, the #include_next in > > /usr/vac/incl

Re: Compiler error of m4-1.4.13 on AIX using xlc

2009-05-20 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Jens Rehsack on 5/16/2009 2:00 AM: > BTW: The xlC-compiler (more: it's header files) on AIX supports a define > _LINUX_SOURCE_COMPAT which enables some linux compatibility behaviour (e.g. > malloc(0) returns a pointer to 0 bytes memory, no

Re: zerosize_ptr mingw problems

2009-05-20 Thread Simon Josefsson
Bruno Haible writes: > Indeed. On mingw, there is a definition of mprotect in libgcc.a ! > > This fixes it: Indeed, thanks. /Simon

Re: zerosize_ptr mingw problems

2009-05-20 Thread Bruno Haible
Simon Josefsson wrote: > The zerosize_ptr stuff doesn't seem to work on MinGW: > > rm -rf m; gnulib-tool --dir m --create-testdir --with-tests memchr; cd m; > ./configure --host=i586-mingw32msvc --build=i686-pc-linux-gnu ; make check > > In file included from test-memchr.c:25: > zerosize-ptr.h:2

Re: sa_family_t

2009-05-20 Thread Bruno Haible
Simon Josefsson wrote: > Mingw and IRIX does not seem to have sa_family_t. IRIX 6.5 has it. But other systems, like Haiku, also lack sa_family_t. Bruno

test-glob.c: fix warning

2009-05-20 Thread Simon Josefsson
Pushed. /Simon >From 68e581a8126f13b42cd8015091cc0b6716df44f7 Mon Sep 17 00:00:00 2001 From: Simon Josefsson Date: Wed, 20 May 2009 09:43:43 +0200 Subject: [PATCH] tests/test-glob.c: Include string.h for strcmp prototype. --- ChangeLog |4 tests/test-glob.c |1 + 2 files c

zerosize_ptr mingw problems

2009-05-20 Thread Simon Josefsson
The zerosize_ptr stuff doesn't seem to work on MinGW: rm -rf m; gnulib-tool --dir m --create-testdir --with-tests memchr; cd m; ./configure --host=i586-mingw32msvc --build=i686-pc-linux-gnu ; make check In file included from test-memchr.c:25: zerosize-ptr.h:27:23: error: sys/mman.h: No such file

getdelim: use SIZE_MAX from stdint.h

2009-05-20 Thread Simon Josefsson
The getdelim module already implicitly depends on stdint, so this patch makes the dependency explicit and reduce code duplication. Pushed. /Simon >From 6e5eee287fe932f23aca494fb8153f218c905771 Mon Sep 17 00:00:00 2001 From: Simon Josefsson Date: Wed, 20 May 2009 09:36:35 +0200 Subject: [PATCH]