summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSascha Schumann <sas@php.net>1999-12-12 10:53:45 +0000
committerSascha Schumann <sas@php.net>1999-12-12 10:53:45 +0000
commitdb27dadf2791a6ba60c843272d8c5059c0f4300c (patch)
tree7b9ac85df63d79d605d7f6e1d3f0fe9d852968f0
parent58a33274c964d329b10b1b3bcfab7fcb93ea4b32 (diff)
downloadphp-git-db27dadf2791a6ba60c843272d8c5059c0f4300c.tar.gz
Call SLS_FETCH() only, if it is needed
-rw-r--r--ext/gd/gd.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/ext/gd/gd.c b/ext/gd/gd.c
index ec3e10eaed..7296b3e919 100644
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
@@ -601,13 +601,14 @@ PHP_FUNCTION(imagegif )
output = php3_header();
if (output) {
- SLS_FETCH();
-
gdImageGif (im, tmp);
fseek(tmp, 0, SEEK_SET);
#if APACHE && defined(CHARSET_EBCDIC)
- /* This is a binary file already: avoid EBCDIC->ASCII conversion */
- ap_bsetflag(((request_rec *) SG(server_context))->connection->client, B_EBCDIC2ASCII, 0);
+ {
+ SLS_FETCH();
+ /* This is a binary file already: avoid EBCDIC->ASCII conversion */
+ ap_bsetflag(((request_rec *) SG(server_context))->connection->client, B_EBCDIC2ASCII, 0);
+ }
#endif
while ((b = fread(buf, 1, sizeof(buf), tmp)) > 0) {
php3_write(buf, b);