From: Rui Hirokawa Date: Sat, 10 Mar 2001 02:03:26 +0000 (+0000) Subject: initialized some strings in global variable structure. X-Git-Tag: php-4.0.5RC1~43 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f3c9c8dd077b28d05a127bfd20c31ac3962e127d;p=php initialized some strings in global variable structure. --- diff --git a/ext/iconv/iconv.c b/ext/iconv/iconv.c index b4fa53ddb2..8b68cd474f 100644 --- a/ext/iconv/iconv.c +++ b/ext/iconv/iconv.c @@ -18,10 +18,11 @@ */ #include "php.h" +#include "php_ini.h" +#include "php_config.h" #if HAVE_ICONV -#include "php_ini.h" #include "php_iconv.h" #include "ext/standard/info.h" @@ -76,10 +77,17 @@ PHP_INI_BEGIN() STD_PHP_INI_ENTRY("iconv.internal_encoding", ICONV_INTERNAL_ENCODING, PHP_INI_ALL, OnUpdateString, internal_encoding, zend_iconv_globals, iconv_globals) PHP_INI_END() +static void +php_iconv_init_globals(zend_iconv_globals *iconv_globals) +{ + iconv_globals->input_encoding = NULL; + iconv_globals->output_encoding = NULL; + iconv_globals->internal_encoding = NULL; +} PHP_MINIT_FUNCTION(iconv) { - ZEND_INIT_MODULE_GLOBALS(iconv, NULL, NULL); + ZEND_INIT_MODULE_GLOBALS(iconv, php_iconv_init_globals, NULL); REGISTER_INI_ENTRIES(); return SUCCESS; } diff --git a/ext/pdf/pdf.c b/ext/pdf/pdf.c index 71c1a582cd..5c03507f9a 100644 --- a/ext/pdf/pdf.c +++ b/ext/pdf/pdf.c @@ -27,6 +27,7 @@ #include "php.h" #include "php_ini.h" #include "php_globals.h" +#include "php_config.h" #include "ext/standard/head.h" #include "ext/standard/info.h" #include "ext/standard/file.h"