ID:               21960
 Comment by:       php-devel at incense dot org
 Reported By:      lorang at e-connect dot lu
 Status:           No Feedback
 Bug Type:         GD related
 Operating System: Linux RedHat
 PHP Version:      4.3.0
 New Comment:

I found various people having problems with ImageTTFText() segfaulting
when run under Apache. I was able to correct that with the following
patch to GD (note: not PHP!)

--- gd-2.0.15.orig/gdft.c       Fri Oct 17 18:22:22 2003
+++ gd-2.0.15/gdft.c    Fri Oct 17 18:22:58 2003
@@ -761,7 +761,7 @@

 /* Persistent font cache until explicitly cleared */
 /*     Fonts can be used across multiple images */
-static gdCache_head_t *fontCache;
+static gdCache_head_t *fontCache = NULL;
 static FT_Library library;

 void
@@ -770,6 +770,7 @@
   if (fontCache)
     {
       gdCacheDelete (fontCache);
+      fontCache = NULL;
       FT_Done_FreeType (library);
     }
 }


Maybe that helps someone, so I'm posting it at the most accurate place
I could find :-)


Previous Comments:
------------------------------------------------------------------------

[2003-02-13 19:46:33] [EMAIL PROTECTED]

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.



------------------------------------------------------------------------

[2003-01-30 07:36:37] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip



------------------------------------------------------------------------

[2003-01-30 03:54:28] lorang at e-connect dot lu

When you create an image with ImageCreateTrueColor in GD 2.0.x and you
try to write on that image with ImageTTFText, the text is not
displayed.
This bug was already reported, and the possible solution was to use an
older version of GD. I think when this BUG was reported, GD 2.0 was
still beta. But not anymore, so !

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=21960&edit=1

Reply via email to