Re: cvs: php4 /ext/standard exec.c
| From: | Hartmut Holzgraefe | Date: | Wed, 28 Jun 2000 06:56:01 +0000 |
| Subject: | Re: cvs: php4 /ext/standard exec.c | ||
| References: | 1 | Groups: | php.cvs |
| Request: | Send a blank email to php-cvs+get-528@lists.php.net to get a copy of this message | ||
Stanislav Malyshev wrote:
>
> SS>> According to SuS II, the behaviour of the implementation is
> SS>> undefined, if the application specifies non-standard
> SS>> characters in the type argument to popen(). In plain English,
> SS>> you probably will get a segfault on Solaris, so that the
> SS>> change is valid.
> SS>>
> SS>> Nevertheless, it looks like the mode "rb" should work with
> SS>> the current glibc code (2.2 CVS) and glibc-2.1.3, because the
> SS>> 'b' is ignored.
>
> I look at 2.1.3 source, and in libio/iopopen.c in function
> _IO_new_proc_open (called from _IO_new_popen) I see:
>
> if (mode[0] == 'r' && mode[1] == '\0')
> ....
> else if (mode[0] == 'w' && mode[1] == '\0')
> ...
> else
> {
> __set_errno (EINVAL);
> return NULL;
> }
>
> Am I looking at the wrong file?
seems that stdio and libio are not in sync in several places where they
should be