Re: cvs: php-src(PHP_5_3) / NEWS configure.in /ext/standard basic_functions.c dns.c dns.h /win32/build config.w32.h.in

From: Date: Wed, 31 Dec 2008 14:35:53 +0000
Subject: Re: cvs: php-src(PHP_5_3) / NEWS configure.in /ext/standard basic_functions.c dns.c dns.h /win32/build config.w32.h.in
References: 1  Groups: php.cvs 
Request: Send a blank email to php-cvs+get-55218@lists.php.net to get a copy of this message
On Wed, Dec 31, 2008 at 15:30, Ilia Alshanetsky <iliaa@php.net> wrote: > iliaa Wed Dec 31 14:30:38 2008 UTC > > Modified files: (Branch: PHP_5_3) > /php-src/ext/standard dns.c dns.h basic_functions.c > /php-src configure.in NEWS > /php-src/win32/build config.w32.h.in > Log: > > [DOC] > Added gethostname() to return the current system host name. > > > http://cvs.php.net/viewvc.cgi/php-src/ext/standard/dns.c?r1=1.70.2.7.2.5.2.9&r2=1.70.2.7.2.5.2.10&diff_format=u > Index: php-src/ext/standard/dns.c > diff -u php-src/ext/standard/dns.c:1.70.2.7.2.5.2.9 > php-src/ext/standard/dns.c:1.70.2.7.2.5.2.10 > --- php-src/ext/standard/dns.c:1.70.2.7.2.5.2.9 Wed Dec 31 11:15:44 2008 > +++ php-src/ext/standard/dns.c Wed Dec 31 14:30:37 2008 > @@ -18,7 +18,7 @@ > +----------------------------------------------------------------------+ > */ > > -/* $Id: dns.c,v 1.70.2.7.2.5.2.9 2008/12/31 11:15:44 sebastian Exp $ */ > +/* $Id: dns.c,v 1.70.2.7.2.5.2.10 2008/12/31 14:30:37 iliaa Exp $ */ > > /* {{{ includes */ > #include "php.h" > @@ -107,6 +107,27 @@ > static char *php_gethostbyaddr(char *ip); > static char *php_gethostbyname(char *name); > > +#ifdef HAVE_GETHOSTNAME > +/* {{{ proto string gethostname() > + Get the host name of the current machine */ > +PHP_FUNCTION(gethostname) > +{ > + char buf[4096]; > + > + if (zend_parse_parameters_none() == FAILURE) { > + WRONG_PARAM_COUNT; This will throw one extra "wrong parameter count" warning. Just use return; like with zend_parse_parameters(). -Hannes

« previous php.cvs (#55218) next »