cvs: php4 /ext/gd gd.c

From: Date: Mon, 30 Jul 2001 20:27:11 +0000
Subject: cvs: php4 /ext/gd gd.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-6427@lists.php.net to get a copy of this message
sniper Mon Jul 30 16:27:11 2001 EDT Modified files: /php4/ext/gd gd.c Log: Make this extension compile in ZTS mode. Also killed 2 compile warnings. Index: php4/ext/gd/gd.c diff -u php4/ext/gd/gd.c:1.144 php4/ext/gd/gd.c:1.145 --- php4/ext/gd/gd.c:1.144 Mon Jul 30 13:29:57 2001 +++ php4/ext/gd/gd.c Mon Jul 30 16:27:11 2001 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: gd.c,v 1.144 2001/07/30 17:29:57 zeev Exp $ */ +/* $Id: gd.c,v 1.145 2001/07/30 20:27:11 sniper Exp $ */ /* gd 1.2 is copyright 1994, 1995, Quest Protein Database Center, Cold Spring Harbor Labs. */ @@ -2167,7 +2167,8 @@ { gdFontPtr font; int ind_type; - + TSRMLS_FETCH(); + switch (size) { case 1: font = gdFontTiny; @@ -3151,7 +3152,7 @@ { #if HAVE_LIBT1 zval **str, **fnt, **sz, **sp, **wd, **ang; - int i, space, add_width, char_width, amount_kern; + int i, space, add_width = 0, char_width, amount_kern; int cur_x, cur_y, dx, dy; int x1, y1, x2, y2, x3, y3, x4, y4; int *f_ind; @@ -3316,7 +3317,8 @@ int dest_height = gdImageSY (im_org); int dest_width = gdImageSX (im_org); int x,y; - + TSRMLS_FETCH(); + im_dest = gdImageCreate (dest_width, dest_height); if (im_dest == NULL) { php_error (E_WARNING, "%s: unable to allocate temporary buffer", get_active_function_name(TSRMLS_C)); @@ -3458,6 +3460,7 @@ default: php_error(E_WARNING, "%s: Format not supported", get_active_function_name(TSRMLS_C)); + RETURN_FALSE; break; }

« previous php.cvs (#6427) next »