Re: zend_parse_parameters
From: Andrei Zmievski Date: Fri, 24 Aug 2001 16:02:44 +0000 Subject: Re: zend_parse_parameters References: 1 2 Groups: php.dev Request: Send a blank email to php-dev+get-64253@lists.php.net to get a copy of this message
On Fri, 24 Aug 2001, Wez Furlong wrote: > When parsing strings from parameters with zend_parse_parameters, it is > required that the programmer pass in an int to receive the length of the > string. > > Could we relax this and allow a NULL instead if we do not need the length > of the string? It would make the calling code more pretty because we > would not need to declare a bunch if ints that don't otherwise get used. > > Yeah, I know about binary safety, but when I'm passing this stuff to binary > unsafe functions there doesn't seem much point :) Initially, I had another specifier that would let you receive just the string pointer, but in discussions with Andi we agreed that it would be good to always return the length as well. Binary safety was a major consideration in this. Don't you think people will start passing NULL all the time if this rule is relaxed? -Andrei It is commonly the case with technologies that you can get the best insight about how they work by watching them fail. -- Neal Stephenson
Thread (65 messages)
- Unknown Message
- The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 /NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS]cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs:php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: cvs: php4 / NEWS /ext/standard info.c /main main.c
- Unknown Message
- The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 /NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS]cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs:php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: cvs: php4 / NEWS /ext/standard info.c /main main.c
- Unknown Message
- The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 /NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS]cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs:php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: cvs: php4 / NEWS /ext/standard info.c /main main.c
- Unknown Message
- The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 /NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS]cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs:php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: Re: The new $_GET/POST/ENV (was: Re: [PHP-CVS] cvs: php4 / NEWS...)
- Re: cvs: php4 / NEWS /ext/standard info.c /main main.c
- Unknown Message
| « previous | php.dev (#64253) | next » |
|---|