Re: Portabilty of poll trick

2021-04-28 Thread Bastien ROUCARIES
Le mar. 27 avr. 2021 à 22:51, Ben Pfaff a écrit : > > On Tue, Apr 27, 2021 at 3:47 PM Bastien ROUCARIES > wrote: > > > > Le mar. 27 avr. 2021 à 22:40, Bruno Haible a écrit : > > > > > > Hi Bastien, > > > > > > > I want to assess the

Time to push passfd API to posix ?

2021-04-27 Thread Bastien ROUCARIES
Hi, It have been 10 year that we invented passfd API, and it was a huge success. I think it is time to submit this API to next revision of POSIX What do you think? Bastien

Re: Portabilty of poll trick

2021-04-27 Thread Bastien ROUCARIES
Le mar. 27 avr. 2021 à 22:40, Bruno Haible a écrit : > > Hi Bastien, > > > I want to assess the safety and portability of the following trick, > > I would want to help you with this, but I can't. You have not stated: > - What is this code supposed to do? I want to shutdown (2) a pipe, in a multi

Re: [PATCH 6/6] Add test for explicit_bzero

2020-04-12 Thread Bastien ROUCARIES
Yes, it does. But I will prefer that you push first the test (I have not written myself and it need comments that are outside my english language skills). So could you push a test ? I will redo my serie above your test On Sun, Apr 12, 2020 at 1:22 PM Bruno Haible wrote: > > Hi Bastien, > > > S

Re: [V2][PATH 0/6] Explicit_bzero improvement

2020-04-12 Thread Bastien ROUCARIES
Thank you for the clarification. I will do it. On Sun, Apr 12, 2020 at 1:33 PM Bruno Haible wrote: > > Hi Bastien, > > > [PATCH 1/6] Use memset_s if possible for explicit_bzero > > [PATCH 2/6] Use SecureZeroMemory on windows for explicit_bzero > > [PATCH 3/6] Support clang for explicit_bzero > >

Re: [PATCH 1/5] Use memset_s if possible for explicit_bzero

2020-04-11 Thread Bastien ROUCARIES
Ok, I will do that. On Sun, Apr 12, 2020 at 12:13 AM Bruno Haible wrote: > > Hello Bastien, > > Allow me a couple of comments, to make you more familiar with gnulib > coding conventions. > > > Some OS define memset_s instead of explicit_bzero. Use it. > > Indeed, FreeBSD 12 and Solaris 11.4 provi

Relicence explicit_bzero to GPL2+/LGPL3 dual

2020-04-06 Thread Bastien ROUCARIES
Hi, Could be possible to relicence this module under dual GPL2+ LGPL3 licence? Code is from glibc thus LGPL2+ and it will be useful for some program like fwknop Bastien

Re: On recent windows fileno return -2 in case of closed stdin, stdout, stderr

2020-04-06 Thread Bastien ROUCARIES
On Mon, Apr 6, 2020 at 8:32 PM Bruno Haible wrote: > > Hi Bastien, > > > according to > > https://docs.microsoft.com/fr-fr/cpp/c-runtime-library/reference/fileno?view=vs-2019 > > > > If stdout or stderr is not associated with an output stream (for > > example, in a Windows application without a c

On recent windows fileno return -2 in case of closed stdin, stdout, stderr

2020-04-06 Thread Bastien ROUCARIES
Hi, according to https://docs.microsoft.com/fr-fr/cpp/c-runtime-library/reference/fileno?view=vs-2019 If stdout or stderr is not associated with an output stream (for example, in a Windows application without a console window), the file descriptor returned is -2. In previous versions, the file d

Re: [Win32] putenv modifications not inherited by child processed (Was: Heap corruption in putenv)

2013-02-19 Thread Bastien ROUCARIES
On Fri, Feb 15, 2013 at 11:24 PM, Eric Blake wrote: > On 02/15/2013 08:10 AM, Michael Goffioul wrote: >> The problem is that the "environ" variable is just a mirror of the >> environment that is manipulated through GetEnvironmentVariable and >> SetEnvironmentVariable. Manipulating the "environ" va

Re: poll() emulation in git

2012-09-05 Thread Bastien ROUCARIES
On Wed, Sep 5, 2012 at 1:24 PM, Joachim Schmitz wrote: >> From: Joachim Schmitz [mailto:j...@schmitz-digital.de] >> Sent: Tuesday, September 04, 2012 1:49 PM >> To: 'Junio C Hamano' >> Cc: 'g...@vger.kernel.org'; 'Erik Faye-Lund' >> Subject: RE: [PATCH v2] Support non-WIN32 system lacking poll() w

Re: gnulib and i18n

2012-09-02 Thread Bastien ROUCARIES
On Sun, Sep 2, 2012 at 11:07 AM, Nguyen Thai Ngoc Duy wrote: > On Sun, Sep 2, 2012 at 1:47 AM, Paul Eggert wrote: >>> Should gnulib generate .pot and maintain its own translations? >> >> That's been proposed, yes, but nobody's gotten around to doing >> it. > > I take it that the project is not ag

Re: Problem with stdbool.h redefining true/false even in C++

2012-08-29 Thread Bastien ROUCARIES
n Wed, Aug 29, 2012 at 7:36 PM, John W. Eaton wrote: > On 29-Aug-2012, Paul Eggert wrote: > > | On 08/29/2012 10:00 AM, John W. Eaton wrote: > | > Why define true, false, and bool to anything when using C++? > | > | Maybe it's for '#ifdef bool' but to be honest I'm just doing what > | GCC does. P

Re: [PATCH] execinfo: new module

2012-08-25 Thread Bastien ROUCARIES
Le 24 août 2012 19:25, "Paul Eggert" a écrit : > > On 08/24/2012 06:47 AM, Bastien ROUCARIES wrote: > > Not until next week. In the mean time could you document that we may need libexecinfo. > > That is documented in the modules/execinfo file, under "Link:&qu

Re: [PATCH] execinfo: new module

2012-08-24 Thread Bastien ROUCARIES
Le 24 août 2012 12:36, "Paul Eggert" a écrit : > > On 08/22/2012 05:16 AM, Bastien ROUCARIES wrote: > > Note that under bsd it will need -lexecinfo see > > http://trac.wxwidgets.org/ticket/9783 > > Thanks for mentioning that. I pushed the following patch, >

Re: Files from gnulib

2012-08-23 Thread Bastien ROUCARIES
[sorry for retrieving this old thread] On Wed, Jan 26, 2011 at 1:02 PM, Jim Meyering wrote: > Eli Zaretskii wrote: >>> From: Bastien ROUCARIES >>> Date: Tue, 25 Jan 2011 23:37:08 +0100 >>> >>> (if and only if doslfn is buggy, and it does not seems accor

Re: target platform compiler

2012-08-23 Thread bastien ROUCARIES
Le Thursday 23 August 2012 11:23:49, Bruno Haible a écrit : > Hi Bastien, > > > Could be possible to get under the section target platform the > > compiler supported? > > You mean in the documentation? Yes in the documentation > gnulib supports all ANSI C compilers, > except those that are evid

target platform compiler

2012-08-23 Thread Bastien ROUCARIES
Hi, Could be possible to get under the section target platform the compiler supported? I have a new idea to get a portable programname but I need to know the compiler used. Bastien

Re: [PATCH] execinfo: new module

2012-08-22 Thread Bastien ROUCARIES
On Wed, Aug 22, 2012 at 10:49 AM, Paul Eggert wrote: > This is for Emacs. Currently, it provides a no-effect stub > on all platforms where it does not already work. > It already works on glibc-based systems, and on Solaris 11. > * lib/execinfo.c, lib/execinfo.in.h, m4/execinfo.m4, modules/execinf

Re: [PATCH] execinfo: new module

2012-08-22 Thread Bastien ROUCARIES
On Wed, Aug 22, 2012 at 10:49 AM, Paul Eggert wrote: > This is for Emacs. Currently, it provides a no-effect stub > on all platforms where it does not already work. > It already works on glibc-based systems, and on Solaris 11. > * lib/execinfo.c, lib/execinfo.in.h, m4/execinfo.m4, modules/execinf

Re: pthreads-win32

2012-08-22 Thread Bastien ROUCARIES
On Wed, Aug 22, 2012 at 12:46 AM, Simon Josefsson wrote: > FYI, this may be of interest: > > http://sources.redhat.com/pthreads-win32/ see more fix here also: https://github.com/GerHobbelt/pthread-win32/commits/master/ > Maybe it would make sense to offer something like that in gnulib, so > that

Re: new module 'system-quote'

2012-05-10 Thread Bastien ROUCARIES
o Haible wrote: > Bastien ROUCARIES wrote: >> Something like this >> >> ^^^%NL%%NL%^%NL%%CR% > > No, this does not work either. > > $ export NL=' > ' > > $ eval `echo "export CR='_'" | tr '_' '\r'`

RE : Re: new module 'system-quote'

2012-05-10 Thread Bastien ROUCARIES
No you need to escape new one the cr Something like this ^^^%NL%%NL%^%NL%%CR% Bastien Le 10 mai 2012 00:41, "Eric Blake" a écrit : On 05/09/2012 04:08 PM, Bruno Haible wrote: > Bastien ROUCARIES wrote: >> Something like this will w... If I understood that page, th

RE : Re: new module 'system-quote'

2012-05-10 Thread Bastien ROUCARIES
echo line1^ line2 Work also and could be simple Maybe echo line1^ \rline2 Will work with \r a not escaped carriage return Le 10 mai 2012 00:07, "Bruno Haible" a écrit : Bastien ROUCARIES wrote: > Something like this will work > http://stackoverflow.com/a/269819 Inde

Re: new module 'system-quote'

2012-05-09 Thread Bastien ROUCARIES
On Wed, May 9, 2012 at 11:23 AM, Bruno Haible wrote: > Eli Zaretskii wrote: >> > Is there any chance that putting a newline or CR in an >> > environment variable, then using %varname%, would allow one to >> > embed such a character? >> >> Not surprisingly, it doesn't work, at least in my testing.

Re: new module 'system-quote'

2012-05-09 Thread Bastien ROUCARIES
On Wed, May 9, 2012 at 3:37 AM, Bruno Haible wrote: > This is the module 'system-quote'. > > It turns out that on native Windows, when going through cmd.exe, it is > not possible to pass arguments that contains a newline ('\n') or a CR ('\r') > character: the command gets truncated at such a chara

Re: MSVC fails to compile floor.c with -fp:strict

2012-03-14 Thread Bastien ROUCARIES
On Wed, Mar 14, 2012 at 11:22 AM, Michael Goffioul wrote: > On Wed, Mar 14, 2012 at 9:48 AM, Bruno Haible wrote: >> Michael Goffioul wrote: >>> I encountered a compilation error with MSVC when compiling floor.c in >>> strict floating-point mode (-fp:strict). >> >> Note that the use of -fp:strict

Re: math error reporting

2012-03-12 Thread Bastien ROUCARIES
On Mon, Mar 12, 2012 at 12:47 PM, Bruno Haible wrote: >> In November 2011, I wrote in >> : >> >>    glibc 2.11:   NaN, fenv bit, errno >>    MacOS X 10.5: NaN, fenv bit          math_errhandling >> (always=MATH_ERREXCEPT) >>    F

Re: SIGPOLL on Darwin

2012-01-31 Thread bastien ROUCARIES
Le Tuesday 31 January 2012 16:19:54, Reuben Thomas a écrit : > gnulib's extensions module turns on _DARWIN_C_SOURCE on Darwin. > Unfortunately, this means that SIGPOLL is not defined, and hence stops > POSIX-compliant code from building (SIGPOLL is mandated by POSIX). As > extensions is required by

Re: new module 'isatty' (was: Re: MS-Windows build of Grep [2/4])

2012-01-03 Thread Bastien ROUCARIES
On Tue, Jan 3, 2012 at 9:36 AM, Eli Zaretskii wrote: >> From: Bruno Haible >> Cc: bastien ROUCARIES , Eli Zaretskii >> , Eric Blake , bonz...@gnu.org, >> bug-g...@gnu.org >> Date: Tue, 03 Jan 2012 03:56:56 +0100 >> >> I'm adding this new mo

Re: Protection of snippet in config.h

2012-01-02 Thread bastien ROUCARIES
Le Monday 2 January 2012 19:06:46, Paul Eggert a écrit : > On 01/02/12 07:46, Bastien ROUCARIES wrote: > > Unfortunatly gnulib add some stuff snippet like noreturn in config.h > > that are not really safe from a fortran point of view. > > Could you explain the problem a bit

Protection of snippet in config.h

2012-01-02 Thread Bastien ROUCARIES
hi, I use regularly gnulib for configuring some fortran program. Therefore I include config.h in the top of my fortran file. Unfortunatly gnulib add some stuff snippet like noreturn in config.h that are not really safe from a fortran point of view. Could be possible to protect these snippet if t

Re: MS-Windows build of Grep [2/4]

2011-12-30 Thread bastien ROUCARIES
Le Wednesday 28 December 2011 18:12:06, Eli Zaretskii a écrit : > > Date: Wed, 28 Dec 2011 17:06:05 +0100 > > From: Bastien ROUCARIES > > Cc: Eli Zaretskii , bug-gnulib , > > bug-g...@gnu.org > > > > Isatty is broken under windows but this not the right fix

RE : Re: MS-Windows build of Grep [2/4]

2011-12-28 Thread Bastien ROUCARIES
Isatty is broken under windows but this not the right fix. In fact isatty under windows is equivalent to test if a file is a char device. Gnat has a better work arround Bastien Le 28 déc. 2011 14:20, "Paolo Bonzini" a écrit : On 12/24/2011 01:59 PM, Eli Zaretskii wrote: > + return > +is

RE : Re: [libvirt] [PATCH] util: fix thinko in runIO

2011-11-26 Thread Bastien ROUCARIES
Malloc page than realloc to smaller does not work ? Bastien Le 25 nov. 2011 14:38, "Eric Blake" a écrit : [adding bug-gnulib; replies can drop libvirt] On 11/25/2011 05:51 AM, Paolo Bonzini wrote: >> Indeed; Linux has posix_memalign, and mingw never runs the io helper >> (although it does comp

RE : isatty() and errno

2011-11-07 Thread Bastien ROUCARIES
isatty should be pached under windows. Try isatty(/dev/null) Bastien Le 8 nov. 2011 00:53, "Eric Blake" a écrit : Our assumption in ptsname.c is that isatty() will set errno on invalid fds. But this is not required by POSIX, and indeed not enforced by Solaris 10; that is, our ptsname.c impleme

Re: math error reporting

2011-11-07 Thread Bastien ROUCARIES
On Sun, Nov 6, 2011 at 8:36 PM, Bruno Haible wrote: > Hi, > > Considering how gnulib-implemented functions should do their > error reporting, I ran a test program to see how the various systems > implement math errors. > > ==

Re: excess precision for 'float'

2011-10-09 Thread Bastien ROUCARIES
On Sun, Oct 9, 2011 at 12:31 AM, Bruno Haible wrote: > It is well-known that 'double' computation results on x86 processors can > carry excess precision. Namely, if the value is stored in a floating-point > register (80 bits total, 64 bits mantissa) without passing through a > memory store, it can

Re: [PATCH] file-has-acl: revert unintended change in behavior of ls -L

2011-10-03 Thread Bastien ROUCARIES
On Mon, Oct 3, 2011 at 8:53 PM, Kamil Dudka wrote: > On Monday 03 October 2011 20:46:59 Bastien ROUCARIES wrote: >> Yes it is possible to mount file and it is call a bind mount. See man page >> of mount, and it is used in pratice essentially for /dev/null but it could >> be

RE : Re: [PATCH] file-has-acl: revert unintended change in behavior of ls -L

2011-10-03 Thread Bastien ROUCARIES
Yes it is possible to mount file and it is call a bind mount. See man page of mount, and it is used in pratice essentially for /dev/null but it could be used for any regular file Le 3 oct. 2011 19:29, "Kamil Dudka" a écrit : On Monday 03 October 2011 18:25:10 Bruno Haible wrote: > Kamil Dudka wr

Re: msvc-inval: more options

2011-09-26 Thread Bastien ROUCARIES
On Mon, Sep 26, 2011 at 11:06 AM, Paolo Bonzini wrote: > On 09/26/2011 11:01 AM, Bruno Haible wrote: >> >> Additionally, there's a legal problem here: Code like > > Stopped reading here.  Do not include snippets, we _can_ do clean-room > reverse engineering if necessary. > > We can also take code

Re: msvc-inval: more options

2011-09-26 Thread Bastien ROUCARIES
On Mon, Sep 26, 2011 at 10:44 AM, Paolo Bonzini wrote: > On 09/26/2011 10:37 AM, Bastien ROUCARIES wrote: >> >> python >> seehttp://svn.python.org/projects/python/trunk/Modules/posixmodule.c >> seems to have solved a lot the maintenabilty stuff by determining the >

Re: msvc-inval: more options

2011-09-26 Thread Bastien ROUCARIES
On Mon, Sep 26, 2011 at 9:01 AM, Paolo Bonzini wrote: > On 09/25/2011 11:46 PM, Bastien ROUCARIES wrote: >> >> Did you seehttp://bugs.python.org/issue4804  ? >> >> Particularlyhttp://bugs.python.org/file12953/__pioinfo.patch >> >> A little bit hackhish but

Re: msvc-inval: more options

2011-09-25 Thread Bastien ROUCARIES
Did you see http://bugs.python.org/issue4804 ? Particularly http://bugs.python.org/file12953/__pioinfo.patch A little bit hackhish but seems to work Thanks bastien On Sun, Sep 25, 2011 at 11:30 PM, Bruno Haible wrote: >> +     * The default way, which is reasonable for programs (not libraries

Re: getting EBADF on MSVC

2011-09-19 Thread Bastien ROUCARIES
On Mon, Sep 19, 2011 at 7:34 AM, Paul Eggert wrote: > On 09/18/11 01:36, Bruno Haible wrote: > >  This patch protects the dup2() calls in gnulib. > > This change has some problems with GNU Emacs, and I suspect there will > be similar problems with printf, close, etc. so let's try to get see > if w

Re: pathmax: support for native Windows

2011-09-13 Thread Bastien ROUCARIES
On Tue, Sep 13, 2011 at 5:33 PM, Bruno Haible wrote: > Bastien ROUCARIES wrote: >> You could use this syntax with win32 api. I used it for opening long >> path and it used byapache on windows. However it will need some >> surgery in order to be used (convert utf8 to uc

Re: pathmax: support for native Windows

2011-09-13 Thread Bastien ROUCARIES
On Tue, Sep 13, 2011 at 2:50 PM, Eric Blake wrote: > On 09/13/2011 06:47 AM, Bastien ROUCARIES wrote: >> >> PATH_MAX is this value for win32 name not for kernel name like \\?\c\. >> It is 32k in this case. > > When using kernel APIs (like cygwin does), then yes, the lim

Re: pathmax: support for native Windows

2011-09-13 Thread Bastien ROUCARIES
PATH_MAX is this value for win32 name not for kernel name like \\?\c\. It is 32k in this case. Bastien On Tue, Sep 13, 2011 at 1:08 PM, Bruno Haible wrote: > Another PATH_MAX related compilation failure on MSVC occurs in lib/stat.c: > > stat.c(76) : fatal error C1189: #error :  "Please port this

Re: MSVC support: documentation

2011-09-11 Thread Bastien ROUCARIES
On Sun, Sep 11, 2011 at 11:05 PM, Michael Goffioul wrote: > On Sun, Sep 11, 2011 at 8:59 PM, Bruno Haible wrote: >> In a current situation, a number of gnulib modules compile flawlessly >> on MSVC 9. Therefore it's time to document its current status. >> >> Further fixes for this platform are, of

Re: 128-bit uid_t

2011-09-11 Thread Bastien ROUCARIES
On Sun, Sep 11, 2011 at 6:41 PM, Bastien ROUCARIES wrote: > n Sun, Sep 11, 2011 at 6:33 PM, Paul Eggert wrote: >> On 09/11/11 08:14, Bastien ROUCARIES wrote: >>> gcc has it : http://gcc.gnu.org/onlinedocs/gcc/_005f_005fint128.html >>> (at least for 64bits) >>

Re: 128-bit uid_t

2011-09-11 Thread Bastien ROUCARIES
n Sun, Sep 11, 2011 at 6:33 PM, Paul Eggert wrote: > On 09/11/11 08:14, Bastien ROUCARIES wrote: >> gcc has it : http://gcc.gnu.org/onlinedocs/gcc/_005f_005fint128.html >> (at least for 64bits) > > I'd be leery of any attempt to define a system type wider than > int

Re: 128-bit uid_t

2011-09-11 Thread Bastien ROUCARIES
On Sun, Sep 11, 2011 at 4:52 PM, Bruno Haible wrote: > Bastien ROUCARIES wrote: >> Did you know >> that recent mscv support a limited int128 (named __int128) under >> 64bits (limited because it does not support divide)? It is quite >> interesting in order to impleme

Re: msvc port: ensure pid_t is defined

2011-09-11 Thread Bastien ROUCARIES
On Sun, Sep 11, 2011 at 2:18 PM, Bruno Haible wrote: > On MSVC 9, the type pid_t is nowhere defined. But POSIX wants it defined in Out of topic but interesting on this kind of subject. Did you know that recent mscv support a limited int128 (named __int128) under 64bits (limited because it does no

Re: [PATCH] freopen SEGFAULT on win32 with filename == NULL

2011-08-31 Thread Bastien ROUCARIES
On Wed, Aug 31, 2011 at 9:54 PM, Bruno Haible wrote: > Bastien ROUCARIES wrote: >> More means to retrieve file name >> - linux /proc/self/fd >> - windows FileInformation  of GetFileInformationByHandleEx >> - freebsd using FDESCFS /dev/fd or proc >> - solaris using

Re: [PATCH] freopen SEGFAULT on win32 with filename == NULL

2011-08-31 Thread Bastien ROUCARIES
On Wed, Aug 31, 2011 at 11:13 AM, Bastien ROUCARIES wrote: > On Wed, Aug 31, 2011 at 10:49 AM, Bruno Haible wrote: >> Claudio Bley wrote: >>> Furthermore, using NULL as filename does not work at all using the MS >>> C runtime library

Re: [PATCH] freopen SEGFAULT on win32 with filename == NULL

2011-08-31 Thread Bastien ROUCARIES
On Wed, Aug 31, 2011 at 10:49 AM, Bruno Haible wrote: > Claudio Bley wrote: >> Furthermore, using NULL as filename does not work at all using the MS >> C runtime library (debug assertion violation). >> >> >> --- freopen.c.1       2011-08-25 21:05:34 +0200 >> +++ freopen.c 2011

Re: Dependencies not compiled in

2011-08-28 Thread Bastien ROUCARIES
Do you know parity ? see http://sourceforge.net/projects/parity/ it is exactly what you need and moreover is better from a loader point of view. If we should support msvc I tyhink we must use this target. Wine thinks to use it for wine under cygwin, and it regularly used at my uni. LD_PRELOAD tric

Re: canonicalize_file_name should support win32 shortcuts

2011-08-26 Thread Bastien ROUCARIES
On Tue, Aug 23, 2011 at 7:47 PM, Eric Blake wrote: > On 08/23/2011 11:31 AM, Sam Steingold wrote: >> >> First of all, newer windows do have symlinks. > > Does mingw support them natively?  If not, then we should get that fixed in > mingw; perhaps by starting with an lstat() that actually works on

RE : Re: errno --> errno name ?

2011-08-05 Thread Bastien ROUCARIES
Does it work for cross compiling ? Bastien Le 5 août 2011 02:39, "Bruno Haible" a écrit : Hi Bruce, > I fixed up the "mk" script to be more portable Indeed, that looks like most portability problems have been eliminated. > tho I haven't tried it on Solaris' /bin/sh. > Probably won't work. I

Re: RE : Re: [PATCH] pipe, pipe2: don't corrupt fd on error

2011-08-04 Thread Bastien ROUCARIES
On Thu, Aug 4, 2011 at 1:00 AM, Eric Blake wrote: > On 06/30/2011 06:57 AM, Eric Blake wrote: >> >> On 06/29/2011 11:22 PM, Bastien ROUCARIES wrote: >>> >>> Could we raise the same issue with socketpair to austin group ? >> >> Good point, I'll

Re: bug #17457: "grep -r foo . > somefile" goes into an infinite loop

2011-07-25 Thread Bastien ROUCARIES
On Mon, Jul 25, 2011 at 10:32 AM, Paolo Bonzini wrote: > On 07/24/2011 09:06 PM, Jim Meyering wrote: >>> >>> >  What about a few POSIX-violating fringe operating systems (Windows and >>> >  DJGPP come to mind)?:)   For Windows we can write our own stat >>> >  function in cygwin, but for DJGPP I th

RE : Re: Fortran95 binding for posix/gnulib

2011-07-20 Thread Bastien ROUCARIES
I agree libcraft is really ugly. Could you review the binding ? Do you have use in octave? Bastien Le 20 juil. 2011 18:44, "John W. Eaton" a écrit : On 3-Jul-2011, Bruno Haible wrote: | subdirectory modules/fortran/ -, and that you follow the GNU ... I wouldn't recommend trying to follow the

Re: [libvirt] mingw: test-poll pipe part fails

2011-07-19 Thread Bastien ROUCARIES
n Tue, Jul 19, 2011 at 6:54 PM, Bastien ROUCARIES wrote: > I have some code if you want that work. If you could test, I wil lsend > you. I have no time to create m4 and proper gnulib integration. It is > up to you Please test, I do not even have compiled it. > Bastien > > On

Re: [libvirt] mingw: test-poll pipe part fails

2011-07-19 Thread Bastien ROUCARIES
I have some code if you want that work. If you could test, I wil lsend you. I have no time to create m4 and proper gnulib integration. It is up to you Bastien On Tue, Jul 19, 2011 at 5:44 PM, Daniel P. Berrange wrote: > On Tue, Jul 19, 2011 at 09:31:59AM -0600, Eric Blake wrote: >> On 07/19/2011

Sysinfo for bsd

2011-07-17 Thread Bastien ROUCARIES
Hi, Something that could be interesting to use for gnulib sysinfo http://code.google.com/p/sysinfo-bsd/source/browse/sysinfo.c Bastien

Re: bug#9076: coreutils-8.12 uses SA_RESETHAND and SA_RESTART unconditionally

2011-07-16 Thread Bastien ROUCARIES
2011/7/15 Eric Blake : > On 07/15/2011 04:28 AM, Pádraig Brady wrote: >> On 15/07/11 08:50, Paul Eggert wrote: >>> On 07/14/11 17:25, Pádraig Brady wrote: I'm not sure about defining these to 0 in gnulib. That will silently ignore the intent of a program on certain platforms. > >> Absolut

Re: EINTR

2011-07-05 Thread Bastien ROUCARIES
On Tue, Jul 5, 2011 at 10:17 AM, Paolo Bonzini wrote: > On 07/03/2011 06:28 PM, Bastien ROUCARIES wrote: >> On Sun, Jul 3, 2011 at 5:36 PM, Bruno Haible  wrote: >>> Hi all, >>> >>> I wrote: >>>> ... in programs that don't install signal

Re: Fortran95 binding for posix/gnulib

2011-07-03 Thread Bastien ROUCARIES
Le dimanche 3 juillet 2011 22:20:07, Bruno Haible a écrit : > Bastien ROUCARIES wrote: > > Fist piece of work will be to creat a gnulib module per posix header. I > > will begin by errno. > > > > How could I get a list of pair name/value of every errno supported on th

Re: Fortran95 binding for posix/gnulib

2011-07-03 Thread Bastien ROUCARIES
Le dimanche 3 juillet 2011 19:32:42, Bruno Haible a écrit : > Hi Bastien, > > > ... binding posix to fortran. > > Yes apparently it requires explicit binding code, cf. [1][2] > > > Would you consider this for inclusion ? > > Yes, why not? Fortran is sufficiently well supported by GCC and by > A

Re: EINTR

2011-07-03 Thread Bastien ROUCARIES
On Sun, Jul 3, 2011 at 5:36 PM, Bruno Haible wrote: > Hi all, > > I wrote: >> ... in programs that don't install signal handlers, EINTR ... also occurs in >> MacOS X! > > It is worse than that: > > 1) Even on Linux, even when the signal handlers have the SA_RESTART flag set, >   some system call (

Fortran95 binding for posix/gnulib

2011-07-03 Thread Bastien ROUCARIES
Hi, Do you think it is worthwhile to contribute module (in fortran95 sense) for binding posix to fortran. I believe it is directly good to use gnulib instead then system posix libc in order to improve portability. Would you consider this for inclusion ? bastien

Re: would like to break sys_select's dependency on sys_socket

2011-06-30 Thread Bastien ROUCARIES
On Thu, Jun 30, 2011 at 11:32 AM, Paul Eggert wrote: > I am planning to make some changes to GNU Emacs which the > gnulib sys_select module would be helpful for.  But sys_select > depends on sys_socket, and that drags in some stuff > like m4/sockpfaf.m4 and m4/sys_uio_h.m4 that I'd rather > avoid.

RE : Re: [PATCH] pipe, pipe2: don't corrupt fd on error

2011-06-29 Thread Bastien ROUCARIES
Could we raise the same issue with socketpair to austin group ? Bastien Le 30 juin 2011 01:13, "Eric Blake" a écrit : On 06/29/2011 04:00 PM, Eric Blake wrote: > I don't know of any race-free way to work around a cygwi... And without a race-free way to work around the cygwin bug, I don't know o

Re: Support of SOCK_CLOEXEC

2011-06-09 Thread Bastien ROUCARIES
Any news of this ? Bastien On Mon, Mar 28, 2011 at 7:07 PM, Bastien ROUCARIES wrote: > On Mon, Mar 28, 2011 at 7:02 PM, Eric Blake wrote: >> On 03/28/2011 10:51 AM, Bastien ROUCARIES wrote: >>> Hi, >>> >>> A mail for getting the status of SOCK_CLOEXEC flags

Re: STDERR_FILENO on HP-UX

2011-06-09 Thread Bastien ROUCARIES
On Thu, Jun 9, 2011 at 11:44 AM, Bruno Haible wrote: > On HP-UX 11.31, I'm seeing this test failure: > >  test-spawn-pipe-child.c:99: assertion failed >  test-spawn-pipe.sh: iteration 4 failed >  test-spawn-pipe-child.c:99: assertion failed >  test-spawn-pipe.sh: iteration 5 failed >  test-spawn-p

Re: [PATCH] openat: reduce syscalls in first probe of /proc

2011-05-10 Thread Bastien ROUCARIES
I disagree here: >       else >         { > +          /* Detect whether /proc/self/fd/../fd exists.  On Linux, that name > +             resolves to /proc/self/fd, which was opened above.  However, on > +             Solaris, it may resolve to /proc/self/fd/fd, which cannot exist, > +            

RE : Re: openat-proc

2011-05-09 Thread Bastien ROUCARIES
09/2011 05:49 AM, Bastien ROUCARIES wrote: > Hi, > > I am trying to modularize openat-proc, i... How can you guarantee that /proc/self/fd/../proc does not exist? If fd is /usr, then it resolves to /usr/../proc which resolves to /proc which does exist. -- Eric Blake ebl...@redhat.com

openat-proc

2011-05-09 Thread Bastien ROUCARIES
Hi, I am trying to modularize openat-proc, in order to create an openat using passfd. I have created a test file for openat-proc, and I think we could a little bit simplify the test of solaris bug, and drop a dependency on same inode. Instead of comparing /proc/self inode why not trying to ope

Re: RFC socketpair

2011-05-03 Thread Bastien ROUCARIES
It seems that we could use DuplicateHandle for the same process see http://support.microsoft.com/kb/150523/en-us Bastien On Tue, May 3, 2011 at 3:00 PM, Bastien ROUCARIES wrote: > On Mon, May 2, 2011 at 3:52 PM, Paolo Bonzini wrote: >> On 05/01/2011 04:29 PM, Bastien ROUCAR

Re: RFC socketpair

2011-05-03 Thread Bastien ROUCARIES
On Mon, May 2, 2011 at 3:52 PM, Paolo Bonzini wrote: > On 05/01/2011 04:29 PM, Bastien ROUCARIES wrote: >> >> Did you test if dup2 work for socket ? >> >> According tohttp://www.suacommunity.com/dictionary/dup-entry.php >> andhttp://blog.csdn.net/linlu11/ar

Re: question about correct usage of gnulib

2011-05-02 Thread Bastien ROUCARIES
On Mon, May 2, 2011 at 12:02 PM, Lorenzo Bettini wrote: > On 04/25/2011 06:36 PM, Bruno Haible wrote: >> >> Lorenzo Bettini wrote: >>> >>> on the manual I read >>> >>> "These Gnulib substitute header files rely on  being already >>> included. Furthermore  must be the first include in every >>> com

Re: RFC socketpair

2011-05-01 Thread Bastien ROUCARIES
>Yes, this is not very clear either. In the meantime you can play safe by > relying only on the inheritance of STDIN_FILENO and STDOUT_FILENO. > >> And unfortunatly socketpair need fd process inherance, so sad :( > > "so sad"? Just copy the 8 line of code relating to dup2() from > tests/test-nonblo

Re: [RFC PATCH] fchdir: move fd shadowing into fd-hook

2011-04-28 Thread Bastien ROUCARIES
> Now there are two ways to proceed: > >  a) Formalize the notion of a set of :AROUND methods for 'dup', 'dup2', >     'dup3', 'fcntl', 'close', in such a way that the first and third code >     can share the same infrastructure. That would mean a file fd-hook2.c, >     similar to fd-hook.c but jus

Re: [PATCH 3/3] passfd: speed up configure and drop unused code

2011-04-21 Thread Bastien ROUCARIES
On Thu, Apr 21, 2011 at 10:26 PM, Eric Blake wrote: > Ultimately, it would be nice to provide a sendmsg and recvmsg module, > and have those provide a replacement struct msghdr and silently > convert msg_accrights into the replacement struct's msg_control, when > targeting older BSD.  But until th

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-21 Thread Bastien ROUCARIES
On Thu, Apr 21, 2011 at 8:59 AM, Ray Satiro wrote: >> On Wed, Apr 20, 2011 at 7:17 PM, Bastien ROUCARIES >>  wrote: >> >> Is the gnulib select() only intended to be used with  nonblocking sockets > on >> >> windows? >> > >> > I have just

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-21 Thread Bastien ROUCARIES
On Thu, Apr 21, 2011 at 8:59 AM, Ray Satiro wrote: >> On Wed, Apr 20, 2011 at 7:17 PM, Bastien ROUCARIES >>  wrote: >> >> Is the gnulib select() only intended to be used with  nonblocking sockets > on >> >> windows? >> > >> > I have just

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-20 Thread Bastien ROUCARIES
>> Spawning a process just to learn if a socket is blocking?  Wow. >> >> Sounds like caching the information independently (like we already do >> for dirfd) is the way to go then, so that we only have to spawn when >> inheriting sockets through stdin/out/err. > > > That is the idea But at least

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-20 Thread Bastien ROUCARIES
On Wed, Apr 20, 2011 at 11:53 PM, Eric Blake wrote: > On 04/20/2011 03:46 PM, Bastien ROUCARIES wrote: >> On Wed, Apr 20, 2011 at 7:17 PM, Bastien ROUCARIES >> wrote: >>>> Is the gnulib select() only intended to be used with nonblocking sockets on >>>>

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-20 Thread Bastien ROUCARIES
On Wed, Apr 20, 2011 at 7:17 PM, Bastien ROUCARIES wrote: >> Is the gnulib select() only intended to be used with nonblocking sockets on >> windows? > > I have just tested the program at the end of the file, it thread is > blocked when enable =0 (block socket) and

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-20 Thread Bastien ROUCARIES
> Is the gnulib select() only intended to be used with nonblocking sockets on > windows? I have just tested the program at the end of the file, it thread is blocked when enable =0 (block socket) and enable=1 it fail with WSAEWOULDBLOCK So i possible stragegy will be: 1. createathread TID from par

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-19 Thread Bastien ROUCARIES
vents through a call to WSAEventSelect or WSAAsyncSelect with FD_ADDRESS_LIST_CHANGE bit set in the network event bitmask. According to http://msdn.microsoft.com/en-us/library/ms741621(v=vs.85).aspx need to test but could work On Tue, Apr 19, 2011 at 4:41 PM, Bastien ROUCARIES wrote: > On Tue

Re: blocking socket is nonblocking after calling gnulib select() in windows

2011-04-19 Thread Bastien ROUCARIES
On Tue, Apr 19, 2011 at 7:33 AM, Ray Satiro wrote: > Hi, > > > Thank you all for your continuous work on gnulib. Every time I look at it it's > evolving. > > Is the gnulib select() only intended to be used with nonblocking sockets on > windows? The Wget project has recently switched to gnulib's re

Re: RFC socketpair

2011-04-19 Thread Bastien ROUCARIES
On Tue, Apr 19, 2011 at 2:08 PM, Bruno Haible wrote: > Hello Bastien, > >> I do not know how to replace the fork() on windows. > > It's replaced by doing a spawn to a separate program. Take for example the > files >  modules/nonblocking-pipe-tests >  tests/test-nonblocking-pipe.sh >  tests/test-no

Re: RFC socketpair

2011-04-18 Thread Bastien ROUCARIES
Le vendredi 8 avril 2011 17:50:02, Bruno Haible a écrit : > Hi Bastien, > > > This program work with AF_INET/AF_INET6 SOCK_STREAM/SOCK_DGRAM under > > linux. > > Did you mean to attach something to your mail? > > Bruno Could you test the following program ? I do not know how to replace the for

Re: RFC socketpair

2011-04-08 Thread Bastien ROUCARIES
Le jeudi 7 avril 2011 01:12:51, Bruno Haible a écrit : > Hi Bastien, > > > A request for comment for a socketpair for windows. > > > > Please comment. > > I think it is too early for us to comment, because it appears that you have > not > > yet started to compile and test the code: > > int > >

RFC socketpair

2011-04-06 Thread Bastien ROUCARIES
Hi, A request for comment for a socketpair for windows. Please comment. In order to support AF_UNIX we will need to do the same thing that with dirfd. Bastien /* Copyright (C) 2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it unde

Re: [PATCH] Fix a typo

2011-03-30 Thread Bastien ROUCARIES
Any news ? On Mon, Mar 28, 2011 at 1:41 PM, Bastien ROUCARIES wrote: > Fix a typo in passfd code > --- >  lib/passfd.c |    1 - >  1 files changed, 0 insertions(+), 1 deletions(-) > > diff --git a/lib/passfd.c b/lib/passfd.c > index 573b80e..ae716a6 100644 > --- a/

Re: non-blocking I/O

2011-03-29 Thread Bastien ROUCARIES
On Tue, Mar 29, 2011 at 6:43 PM, Bastien ROUCARIES wrote: > On Tue, Mar 29, 2011 at 6:34 PM, Bastien ROUCARIES > wrote: >> On Tue, Mar 29, 2011 at 5:16 PM, Bruno Haible wrote: >>> Paolo Bonzini wrote: >>>> Without guessing what your bias is, I also

Re: non-blocking I/O

2011-03-29 Thread Bastien ROUCARIES
On Tue, Mar 29, 2011 at 6:34 PM, Bastien ROUCARIES wrote: > On Tue, Mar 29, 2011 at 5:16 PM, Bruno Haible wrote: >> Paolo Bonzini wrote: >>> Without guessing what your bias is, I also :) prefer to implement >>> {g,s}et_nonblock_flag functions.  It would use either >

Re: non-blocking I/O

2011-03-29 Thread Bastien ROUCARIES
On Tue, Mar 29, 2011 at 5:16 PM, Bruno Haible wrote: > Paolo Bonzini wrote: >> Without guessing what your bias is, I also :) prefer to implement >> {g,s}et_nonblock_flag functions.  It would use either >> SetNamedPipeHandleState or ioctlsocket (using the socket detection trick >> in sockets.c to d

  1   2   >