Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:15619 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 87022 invoked by uid 1010); 26 Mar 2005 02:51:03 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 87007 invoked from network); 26 Mar 2005 02:51:03 -0000 Received: from unknown (HELO iki.fi) (127.0.0.1) by localhost with SMTP; 26 Mar 2005 02:51:03 -0000 X-Host-Fingerprint: 195.197.172.116 gw02.mail.saunalahti.fi Linux 2.4/2.6 Received: from ([195.197.172.116:60811] helo=gw02.mail.saunalahti.fi) by pb1.pair.com (ecelerity HEAD r(5268)) with SMTP id 40/3B-08971-71EC4424 for ; Fri, 25 Mar 2005 21:51:03 -0500 Received: from nest.netphobia.fi (YZCLXVIII.dsl.saunalahti.fi [85.76.34.69]) by gw02.mail.saunalahti.fi (Postfix) with ESMTP id 8CB0ABB7D0; Sat, 26 Mar 2005 04:51:00 +0200 (EET) Received: from nest.netphobia.fi (nest.netphobia.fi [127.0.0.1]) by nest.netphobia.fi (8.13.1/8.13.1) with ESMTP id j2Q2p0ap031965; Sat, 26 Mar 2005 04:51:00 +0200 Received: from localhost (jani@localhost) by nest.netphobia.fi (8.13.1/8.13.1/Submit) with ESMTP id j2Q2oxR3031962; Sat, 26 Mar 2005 04:51:00 +0200 X-Authentication-Warning: nest.netphobia.fi: jani owned process doing -bs Date: Sat, 26 Mar 2005 04:50:59 +0200 (EET) Reply-To: Jani Taskinen To: Joe Orton Cc: internals@lists.php.net In-Reply-To: <20050324131116.GA10316@redhat.com> Message-ID: References: <20050324131116.GA10316@redhat.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Subject: Re: [PHP-DEV] [PATCH] mysqli: remove global symbols From: sniper@iki.fi (Jani Taskinen) If anyone objects, they'll morons. Just commit. --Jani On Thu, 24 Mar 2005, Joe Orton wrote: > Any objections to this patch? mysqli is defining a bunch of global > symbols which it looks like it doesn't need to. Not urgent for 5.0.4. > > --- php-5.0.3/ext/mysqli/mysqli_prop.c.mysqliglobal > +++ php-5.0.3/ext/mysqli/mysqli_prop.c > @@ -57,7 +57,7 @@ > p = (MYSQL_STMT *)((MY_STMT *)((MYSQLI_RESOURCE *)(obj->ptr))->ptr)->stmt > > #define MYSQLI_MAP_PROPERTY_FUNC_LONG( __func, __int_func, __get_type, __ret_type)\ > -int __func(mysqli_object *obj, zval **retval TSRMLS_DC) \ > +static int __func(mysqli_object *obj, zval **retval TSRMLS_DC) \ > {\ > __ret_type l;\ > __get_type;\ > @@ -77,7 +77,7 @@ > } > > #define MYSQLI_MAP_PROPERTY_FUNC_STRING(__func, __int_func, __get_type)\ > -int __func(mysqli_object *obj, zval **retval TSRMLS_DC)\ > +static int __func(mysqli_object *obj, zval **retval TSRMLS_DC)\ > {\ > char *c;\ > __get_type;\ > @@ -95,7 +95,7 @@ > } > > /* {{{ property link_client_version_read */ > -int link_client_version_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int link_client_version_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > ALLOC_ZVAL(*retval); > ZVAL_LONG(*retval, MYSQL_VERSION_ID); > @@ -104,7 +104,7 @@ > /* }}} */ > > /* {{{ property link_client_info_read */ > -int link_client_info_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int link_client_info_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > ALLOC_ZVAL(*retval); > ZVAL_STRING(*retval, MYSQL_SERVER_VERSION, 1); > @@ -113,7 +113,7 @@ > /* }}} */ > > /* {{{ property link_connect_errno_read */ > -int link_connect_errno_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int link_connect_errno_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > ALLOC_ZVAL(*retval); > ZVAL_LONG(*retval, (long)MyG(error_no)); > @@ -122,7 +122,7 @@ > /* }}} */ > > /* {{{ property link_connect_error_read */ > -int link_connect_error_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int link_connect_error_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > ALLOC_ZVAL(*retval); > ZVAL_STRING(*retval, MyG(error_msg), 1); > @@ -148,7 +148,7 @@ > /* result properties */ > > /* {{{ property result_type_read */ > -int result_type_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int result_type_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > MYSQL_RES *p; > > @@ -167,7 +167,7 @@ > /* }}} */ > > /* {{{ property result_lengths_read */ > -int result_lengths_read(mysqli_object *obj, zval **retval TSRMLS_DC) > +static int result_lengths_read(mysqli_object *obj, zval **retval TSRMLS_DC) > { > MYSQL_RES *p; > > >