Fixed build with GD 1.8.4

This commit is contained in:
Ilia Alshanetsky 2002-12-10 17:57:41 +00:00
parent 28c32e1fc8
commit 99f2b9674f

View File

@ -1591,12 +1591,14 @@ static void _php_image_output(INTERNAL_FUNCTION_PARAMETERS, int image_type, char
}
(*func_p)(im, i, fp);
break;
#if HAVE_LIBGD20
case PHP_GDIMG_TYPE_GD:
if(im->trueColor){
gdImageTrueColorToPalette(im,1,256);
}
(*func_p)(im, fp);
break;
#endif
default:
(*func_p)(im, fp);
break;
@ -1628,12 +1630,14 @@ static void _php_image_output(INTERNAL_FUNCTION_PARAMETERS, int image_type, char
}
(*func_p)(im, q, tmp);
break;
#if HAVE_LIBGD20
case PHP_GDIMG_TYPE_GD:
if (im->trueColor) {
gdImageTrueColorToPalette(im,1,256);
}
(*func_p)(im, tmp);
break;
#endif
default:
(*func_p)(im, tmp);
break;