From: Sander Roobol Date: Fri, 29 Nov 2002 18:05:22 +0000 (+0000) Subject: MFH X-Git-Tag: php-4.3.0RC3~107 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1ec334a99fe14681baadc2f8682951ff22aa388b;p=php MFH --- diff --git a/ext/bcmath/libbcmath/src/init.c b/ext/bcmath/libbcmath/src/init.c index f349d82a7b..14e84f52e2 100644 --- a/ext/bcmath/libbcmath/src/init.c +++ b/ext/bcmath/libbcmath/src/init.c @@ -38,7 +38,9 @@ #include "bcmath.h" #include "private.h" +#ifdef SANDER_0 bc_num _bc_Free_list = NULL; +#endif /* new_num allocates a number and sets fields to known values. */ diff --git a/ext/bcmath/libbcmath/src/private.h b/ext/bcmath/libbcmath/src/private.h index 4458346626..0789677d95 100644 --- a/ext/bcmath/libbcmath/src/private.h +++ b/ext/bcmath/libbcmath/src/private.h @@ -32,7 +32,9 @@ /* "Private" routines to bcmath. */ /* variables */ +#ifdef SANDER_0 extern bc_num _bc_Free_list; +#endif /* routines */ int _bc_do_compare (bc_num n1, bc_num n2, int use_sign, int ignore_last); diff --git a/ext/bcmath/libbcmath/src/recmul.c b/ext/bcmath/libbcmath/src/recmul.c index f97614c535..c31d09dc72 100644 --- a/ext/bcmath/libbcmath/src/recmul.c +++ b/ext/bcmath/libbcmath/src/recmul.c @@ -57,13 +57,17 @@ new_sub_num (length, scale, value) { bc_num temp; +#ifdef SANDER_0 if (_bc_Free_list != NULL) { temp = _bc_Free_list; _bc_Free_list = temp->n_next; } else { +#endif temp = (bc_num) emalloc (sizeof(bc_struct)); +#ifdef SANDER_0 if (temp == NULL) bc_out_of_memory (); } +#endif temp->n_sign = PLUS; temp->n_len = length; temp->n_scale = scale;