Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.1.3

Bug #17353 GD Image font functions given string parameters where integers expected
Submitted: 2010-04-28 18:57 UTC
From: rsafran Assigned: doconnor
Status: Closed Package: Image_Barcode (version 1.1.0)
PHP Version: 5.3.2 OS: Linux 2.6.31-gentoo-r1
Roadmaps: (Not assigned)    
Subscription  


 [2010-04-28 18:57 UTC] rsafran (Richard Safran)
Description: ------------ Received the following error messages after upgrading from PHP 5.2.13 to 5.3.2: PHP Warning: imagefontheight() expects parameter 1 to be long, string given in /usr/share/php5/PEAR/Image/Barcode/Code39.php on line 186 PHP Warning: imagefontwidth() expects parameter 1 to be long, string given in /usr/share/php5/PEAR/Image/Barcode/Code39.php on line 187 PHP Warning: imagestring() expects parameter 2 to be long, string given in /usr/share/php5/PEAR/Image/Barcode/Code39.php on line 225 The parameter being passed is the literal string "GDFontSmall". The manual page for these functions say that the parameter must be an integer representing a known font. The barcode image is returned, but the text underneath the code is not present. Test script: --------------- <?php require_once 'Image/Barcode.php'; Image_Barcode::draw(123456, 'Code39', 'png'); ?> Expected result: ---------------- The barcode image should include the text of the numeric value Actual result: -------------- The barcode image without the text

Comments

 [2010-10-10 15:21 UTC] gemorroj (Gemor Roj)
Added patch path.
 [2011-12-10 17:44 UTC] doconnor (Daniel O'Connor)
-Status: Open +Status: Closed -Assigned To: +Assigned To: doconnor
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.