#38742 [WFx]: hebrew letters not converted properly
ID: 38742 User updated by: ashabi at yahoo dot com Reported By: ashabi at yahoo dot com Status: Wont fix Bug Type: *Unicode Issues Operating System: windows PHP Version: 4.4.4 New Comment: Still doesn't explain why the $REQUEST function works ok but the explode function does not. Previous Comments: [2006-09-07 19:02:26] [EMAIL PROTECTED] You have to wait for PHP6 if you need Unicode support. [2006-09-07 18:46:57] ashabi at yahoo dot com Description: When I explode a URL it does not display the hebrew character in my URL properly. Reproduce code: --- $page = explode("/", $_SERVER['PATH_INFO']); $letter = $page[7]; echo $letter; $page[7] is a hebrew letter. Expected result: For example: à Actual result: -- For example: × FYI - If I were to use the $_REQUEST function then it would display the hebrew letter properly. -- Edit this bug report at http://bugs.php.net/?id=38742&edit=1
#38766 [NEW]: Nonbreaking whitespace breaks parsing
From: a at b dot c dot de Operating system: Windows XP SP2 PHP version: 5.1.6 PHP Bug Type: Feature/Change Request Bug description: Nonbreaking whitespace breaks parsing Description: In most (Windows) fonts, character 0xa0 renders as a blank (nonbreaking) space. Some people use text editors that for whatever reason like to use 0xa0 at random locations instead of ordinary spaces. The result is code that _looks_ correct, but when run can trigger a parse error for no apparent reason. In zend_language_scanner.l, 0xa0 is recognised as a LABEL character (which means, among other things, that you could have a variable called "$ ");. Assuming no-one is perverted enough to do something like that, it should be safe to reassign it to WHITESPACE (will this cause grief in other character sets?). Reproduce code: --- Expected result: Hello, World Hello, World Hello, World Hello, World Hello, World Actual result: -- Parse error: parse error, unexpected T_ECHO in C:\test.php on line 5 -- Edit bug report at http://bugs.php.net/?id=38766&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=38766&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=38766&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=38766&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=38766&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=38766&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=38766&r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=38766&r=needscript Try newer version:http://bugs.php.net/fix.php?id=38766&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=38766&r=support Expected behavior:http://bugs.php.net/fix.php?id=38766&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=38766&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=38766&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=38766&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38766&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=38766&r=dst IIS Stability:http://bugs.php.net/fix.php?id=38766&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=38766&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=38766&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=38766&r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=38766&r=mysqlcfg
#38764 [Bgs]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 User updated by: markg852 at hotmail dot com Reported By: markg852 at hotmail dot com Status: Bogus Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 Assigned To: pajoye New Comment: Thanx alot that worked how i wanted it. but it might be a idea to put something like this in the php documentation aswell.. maybe here: http://nl3.php.net/manual/en/function.imagefill.php i couldn`t find it anywhere and people on the ##php channal (irc) on freenode couldn`t offer a solution aswell.. so this might be verry unknown. Again Thanx Previous Comments: [2006-09-09 23:28:57] [EMAIL PROTECTED] First of all no need to be loud. It was not a suggestion but a fact. In this image "uitkomstvc4.png", the left sude shows the artifacts resulting from a wrong/no transparent color. Just try: $thumb = imagecreatetruecolor($newwidth, $newheight); imagefill($thumb,0,0, 0xff); .. do the copy/save with transparent color or blend mode.. and then do the copy, you will have what you have on the right side. It is all about alpha component and background color of two separate images. Again, there is no bug, not in the gd and not in php. [2006-09-09 22:28:51] markg852 at hotmail dot com @ [EMAIL PROTECTED] i even tested the 6.0.0-dev snapshot and it still has the exact same issue. @ [EMAIL PROTECTED] tested your suggestion and the result is still exactly the same. and just to be sore.. i`m talking about the QUALITY!!! that`s just different.. just look at the image i supplied in the first image. Could this be a bug in GD itself (so not php`s fault) or in php_gd.dll ? [2006-09-09 22:16:22] [EMAIL PROTECTED] doh, submit too quickly all you have to do: imagecolortransparent($thumb, 0); imagealphablending($thumb, false); the fist to set the bgd color, the second function to keep the alpha information while copying (no blend ops). [2006-09-09 22:13:18] [EMAIL PROTECTED] There is no bug. You copy an image to a another image. The destination image has no transparent color defined. True color images are "filled" with black by default, that's why you see black instead of the transparent color. short version: all you need to do is: ImageColorTransparent($thumb, 0); [2006-09-09 21:51:58] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38764 -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [Bgs]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 Updated by: [EMAIL PROTECTED] Reported By: markg852 at hotmail dot com Status: Bogus Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 Assigned To: pajoye New Comment: First of all no need to be loud. It was not a suggestion but a fact. In this image "uitkomstvc4.png", the left sude shows the artifacts resulting from a wrong/no transparent color. Just try: $thumb = imagecreatetruecolor($newwidth, $newheight); imagefill($thumb,0,0, 0xff); .. do the copy/save with transparent color or blend mode.. and then do the copy, you will have what you have on the right side. It is all about alpha component and background color of two separate images. Again, there is no bug, not in the gd and not in php. Previous Comments: [2006-09-09 22:28:51] markg852 at hotmail dot com @ [EMAIL PROTECTED] i even tested the 6.0.0-dev snapshot and it still has the exact same issue. @ [EMAIL PROTECTED] tested your suggestion and the result is still exactly the same. and just to be sore.. i`m talking about the QUALITY!!! that`s just different.. just look at the image i supplied in the first image. Could this be a bug in GD itself (so not php`s fault) or in php_gd.dll ? [2006-09-09 22:16:22] [EMAIL PROTECTED] doh, submit too quickly all you have to do: imagecolortransparent($thumb, 0); imagealphablending($thumb, false); the fist to set the bgd color, the second function to keep the alpha information while copying (no blend ops). [2006-09-09 22:13:18] [EMAIL PROTECTED] There is no bug. You copy an image to a another image. The destination image has no transparent color defined. True color images are "filled" with black by default, that's why you see black instead of the transparent color. short version: all you need to do is: ImageColorTransparent($thumb, 0); [2006-09-09 21:51:58] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 21:47:45] markg852 at hotmail dot com The bug is in imagecopyresampled() AND imagecopyresized()!! The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38764 -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38762 [Asn->Opn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 Updated by: [EMAIL PROTECTED] Reported By: butterblume83 at gmx dot de -Status: Assigned +Status: Open Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 Assigned To: sesser New Comment: The flex check works. The behaviour introduced with PHP 5.2 was unwanted. The original reporter reported the issue with PHP 5.1.6 which is proof enough, that my change that is only in 5.2 is NOT responsible. Previous Comments: [2006-09-09 21:38:58] [EMAIL PROTECTED] Stefan, your change broke the check for flex: http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.332.2.14.2.1&r2=1.332.2.14.2.2 [2006-09-09 21:27:25] butterblume83 at gmx dot de It works after I downgraded flex (2.5.31-38) to flex-old (2.5.4a-7). Please edit php's configure script so that a fatal error is thrown if the flex version is invalid. [2006-09-09 21:13:51] [EMAIL PROTECTED] Can't reproduce. [2006-09-09 20:35:08] butterblume83 at gmx dot de Is the configure-line: checking for flex version... invalid interesting? [2006-09-09 20:31:50] butterblume83 at gmx dot de @tony2001: does not help. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38762 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38764 [Bgs]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 User updated by: markg852 at hotmail dot com Reported By: markg852 at hotmail dot com Status: Bogus Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 Assigned To: pajoye New Comment: @ [EMAIL PROTECTED] i even tested the 6.0.0-dev snapshot and it still has the exact same issue. @ [EMAIL PROTECTED] tested your suggestion and the result is still exactly the same. and just to be sore.. i`m talking about the QUALITY!!! that`s just different.. just look at the image i supplied in the first image. Could this be a bug in GD itself (so not php`s fault) or in php_gd.dll ? Previous Comments: [2006-09-09 22:16:22] [EMAIL PROTECTED] doh, submit too quickly all you have to do: imagecolortransparent($thumb, 0); imagealphablending($thumb, false); the fist to set the bgd color, the second function to keep the alpha information while copying (no blend ops). [2006-09-09 22:13:18] [EMAIL PROTECTED] There is no bug. You copy an image to a another image. The destination image has no transparent color defined. True color images are "filled" with black by default, that's why you see black instead of the transparent color. short version: all you need to do is: ImageColorTransparent($thumb, 0); [2006-09-09 21:51:58] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 21:47:45] markg852 at hotmail dot com The bug is in imagecopyresampled() AND imagecopyresized()!! [2006-09-09 21:45:27] markg852 at hotmail dot com Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [Bgs]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 Updated by: [EMAIL PROTECTED] Reported By: markg852 at hotmail dot com Status: Bogus Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 Assigned To: pajoye New Comment: doh, submit too quickly all you have to do: imagecolortransparent($thumb, 0); imagealphablending($thumb, false); the fist to set the bgd color, the second function to keep the alpha information while copying (no blend ops). Previous Comments: [2006-09-09 22:13:18] [EMAIL PROTECTED] There is no bug. You copy an image to a another image. The destination image has no transparent color defined. True color images are "filled" with black by default, that's why you see black instead of the transparent color. short version: all you need to do is: ImageColorTransparent($thumb, 0); [2006-09-09 21:51:58] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 21:47:45] markg852 at hotmail dot com The bug is in imagecopyresampled() AND imagecopyresized()!! [2006-09-09 21:45:27] markg852 at hotmail dot com Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [Fbk->Bgs]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 Updated by: [EMAIL PROTECTED] Reported By: markg852 at hotmail dot com -Status: Feedback +Status: Bogus Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 -Assigned To: +Assigned To: pajoye New Comment: There is no bug. You copy an image to a another image. The destination image has no transparent color defined. True color images are "filled" with black by default, that's why you see black instead of the transparent color. short version: all you need to do is: ImageColorTransparent($thumb, 0); Previous Comments: [2006-09-09 21:51:58] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 21:47:45] markg852 at hotmail dot com The bug is in imagecopyresampled() AND imagecopyresized()!! [2006-09-09 21:45:27] markg852 at hotmail dot com Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [Opn->Fbk]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 Updated by: [EMAIL PROTECTED] Reported By: markg852 at hotmail dot com -Status: Open +Status: Feedback Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 New Comment: Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip Previous Comments: [2006-09-09 21:47:45] markg852 at hotmail dot com The bug is in imagecopyresampled() AND imagecopyresized()!! [2006-09-09 21:45:27] markg852 at hotmail dot com Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [Opn]: GD imagecopyresampled() AND imagecopyresized() bug
ID: 38764 User updated by: markg852 at hotmail dot com -Summary: GD imagecopyresampled() bug Reported By: markg852 at hotmail dot com Status: Open Bug Type: GD related Operating System: Windows XP, linux PHP Version: 5.1.6 New Comment: The bug is in imagecopyresampled() AND imagecopyresized()!! Previous Comments: [2006-09-09 21:45:27] markg852 at hotmail dot com Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit this bug report at http://bugs.php.net/?id=38764&edit=1
#38764 [NEW]: GD imagecopyresampled() bug
From: markg852 at hotmail dot com Operating system: Windows XP, linux PHP version: 5.1.6 PHP Bug Type: GD related Bug description: GD imagecopyresampled() bug Description: This bug can be found when trying to make a thumbnail from a url (example: http://promote.opera.com/logos/Opera5_t.png) the png isn`t even transperant anymore unless these 3 lines of code are also added: $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel i tried everything i could thing of but the quality stays different.. What the code below does is the following: 1. It downloaded the opera logo png image and makes a thumbnail of the URL!! 2. (after hitting F5) the code will make another thumbnail from the downloaded full scale image. 3. (after hitting F5 2nd time) the code will show both thumbnails and look at the quality difference!! and without the 3 lines posted above the "ugly" image has a black background!! Reproduce code: --- '; echo "Thumbnail made from URL"; echo ''; echo "This one is made from a PATH"; exit; } elseif (file_exists('./Opera5_t.png')) { $filename = 'Opera5_t.png'; $mid = 'van_path'; } else { $filename = 'http://promote.opera.com/logos/Opera5_t.png'; $mid = 'van_url'; imagepng(imagecreatefrompng('http://promote.opera.com/logos/Opera5_t.png'), 'Opera5_t.png'); } $percent = 0.1; // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); $source = imagecreatefrompng($filename); $background = imagecolorallocate($thumb, 0, 0, 0); ImageColorTransparent($thumb, $background); // make the new temp image all transparent imagealphablending($thumb, false); // turn off the alpha blending to keep the alpha channel // Resize imagecopyresampled($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output imagepng($thumb, 'thumb_' . $mid . '.png'); echo ''; // Content type // header('Content-type: image/png'); // readfile('thumb_' . $mid . '.png'); ?> Expected result: http://img393.imageshack.us/img393/2796/uitkomstvc4.png -- Edit bug report at http://bugs.php.net/?id=38764&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=38764&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=38764&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=38764&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=38764&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=38764&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=38764&r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=38764&r=needscript Try newer version:http://bugs.php.net/fix.php?id=38764&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=38764&r=support Expected behavior:http://bugs.php.net/fix.php?id=38764&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=38764&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=38764&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=38764&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38764&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=38764&r=dst IIS Stability:http://bugs.php.net/fix.php?id=38764&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=38764&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=38764&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=38764&r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=38764&r=mysqlcfg
#38762 [Opn->Asn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 Updated by: [EMAIL PROTECTED] Reported By: butterblume83 at gmx dot de -Status: Open +Status: Assigned Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 -Assigned To: +Assigned To: sesser New Comment: Stefan, your change broke the check for flex: http://cvs.php.net/viewvc.cgi/php-src/acinclude.m4?r1=1.332.2.14.2.1&r2=1.332.2.14.2.2 Previous Comments: [2006-09-09 21:27:25] butterblume83 at gmx dot de It works after I downgraded flex (2.5.31-38) to flex-old (2.5.4a-7). Please edit php's configure script so that a fatal error is thrown if the flex version is invalid. [2006-09-09 21:13:51] [EMAIL PROTECTED] Can't reproduce. [2006-09-09 20:35:08] butterblume83 at gmx dot de Is the configure-line: checking for flex version... invalid interesting? [2006-09-09 20:31:50] butterblume83 at gmx dot de @tony2001: does not help. [2006-09-09 20:13:40] [EMAIL PROTECTED] Make sure you have yacc/bison installed. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38762 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Fbk->Opn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 User updated by: butterblume83 at gmx dot de Reported By: butterblume83 at gmx dot de -Status: Feedback +Status: Open Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: It works after I downgraded flex (2.5.31-38) to flex-old (2.5.4a-7). Please edit php's configure script so that a fatal error is thrown if the flex version is invalid. Previous Comments: [2006-09-09 21:13:51] [EMAIL PROTECTED] Can't reproduce. [2006-09-09 20:35:08] butterblume83 at gmx dot de Is the configure-line: checking for flex version... invalid interesting? [2006-09-09 20:31:50] butterblume83 at gmx dot de @tony2001: does not help. [2006-09-09 20:13:40] [EMAIL PROTECTED] Make sure you have yacc/bison installed. [2006-09-09 20:09:43] butterblume83 at gmx dot de @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38762 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Opn->Fbk]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 Updated by: [EMAIL PROTECTED] Reported By: butterblume83 at gmx dot de -Status: Open +Status: Feedback Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: Can't reproduce. Previous Comments: [2006-09-09 20:35:08] butterblume83 at gmx dot de Is the configure-line: checking for flex version... invalid interesting? [2006-09-09 20:31:50] butterblume83 at gmx dot de @tony2001: does not help. [2006-09-09 20:13:40] [EMAIL PROTECTED] Make sure you have yacc/bison installed. [2006-09-09 20:09:43] butterblume83 at gmx dot de @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. [2006-09-09 19:48:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38762 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38757 [Opn->Asn]: MultiPart Form Uploads fail with FastCGI
ID: 38757 Updated by: [EMAIL PROTECTED] Reported By: davidb at pins dot net -Status: Open +Status: Assigned Bug Type: Apache related Operating System: Solaris 8 PHP Version: 5.1.6 -Assigned To: +Assigned To: dmitry New Comment: Dmitry, could you plz check it out? Previous Comments: [2006-09-09 02:05:01] davidb at pins dot net Well, I tried with the latest 5.2b snapshot, and now it's broken for my PC at home also. Appears to be the identical problem - php just silently stops processing after it reads in the POST data, closes the socket, and then waits for the next request, throwing a 500 server error. Please. [2006-09-08 22:09:08] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-08 22:04:15] davidb at pins dot net Description: Greetings. I'm currently observing a reproducible version of bug #26647 in the PHP 5.1 train. For a subset of users running mostly Mac but some PC browsers, the PHP process unceremoniously exists witout comment when the form is POST'ed. A truss of the PHP FastCGI process shows PHP reading in the text (incidently, it's also pointed out a performance issue where php's doing a read() of 8 bytes at a time from the FastCGI stream instead of 8kB at at a time, but I digress). The problem appears to go away when I switch to a non-FastCGI version. The broken users are broken consistently - it would be possible (and easy) to gdb trace it and see why it's exiting. Here's the start/end of the truss: accept(0, 0xFFBEDA50, 0xFFBED99C, 1)= 4 fcntl(0, F_SETLK, 0xFFBEDA28) = 0 poll(0xFFBED8F0, 1, 1000) = 0 shutdown(4, 1, 1) = 0 recv(4, "0101\001\0\b\0\0", 8, 0) = 8 recv(4, "\001\0\0\0\0\0\0", 8, 0) = 8 recv(4, "0104\001\015\0\0", 8, 0) = 8 recv(4, "0E05 C O N T E N", 8, 0) = 8 recv(4, " T _ L E N G T H", 8, 0) = 8 recv(4, " 8 3 5 1 90104\0", 8, 0) = 8 recv(4, "01\0 d\0\0\f V C", 8, 0) = 8 recv(4, " O N T E N T _ T", 8, 0) = 8 recv(4, " Y P E m u l t i", 8, 0) = 8 recv(4, " p a r t / f o r", 8, 0) = 8 recv(4, " m - d a t a ; ", 8, 0) = 8 recv(4, " b o u n d a r y", 8, 0) = 8 recv(4, " m L b O u N d A", 8, 0) = 8 (many many lines) recv(4, " r Y - -\r\n0105", 8, 0) = 8 recv(4, "\001\0\0\0\0", 8, 0) = 6 recv(4, 0xFFBEDA28, 8, 0) = 0 close(4)= 0 fcntl(0, F_SETLKW, 0xFFBEDA28) = 0 accept(0, 0xFFBEDA50, 0xFFBED99C, 1) (sleeping...) Bam. Goodbye. No error, no nothing. Reproduce code: --- Expected result: The response.php should work - note, however, that php never even attempts to open the response.php file, which is just a trivial "file uploaded" message, no attempt to save. Actual result: -- See above truss - php just exits. -- Edit this bug report at http://bugs.php.net/?id=38757&edit=1
#38762 [Opn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 User updated by: butterblume83 at gmx dot de Reported By: butterblume83 at gmx dot de Status: Open Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: Is the configure-line: checking for flex version... invalid interesting? Previous Comments: [2006-09-09 20:31:50] butterblume83 at gmx dot de @tony2001: does not help. [2006-09-09 20:13:40] [EMAIL PROTECTED] Make sure you have yacc/bison installed. [2006-09-09 20:09:43] butterblume83 at gmx dot de @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. [2006-09-09 19:48:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 19:30:45] butterblume83 at gmx dot de Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Fbk->Opn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 User updated by: butterblume83 at gmx dot de Reported By: butterblume83 at gmx dot de -Status: Feedback +Status: Open Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: @tony2001: does not help. Previous Comments: [2006-09-09 20:13:40] [EMAIL PROTECTED] Make sure you have yacc/bison installed. [2006-09-09 20:09:43] butterblume83 at gmx dot de @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. [2006-09-09 19:48:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 19:30:45] butterblume83 at gmx dot de Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Opn->Fbk]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 Updated by: [EMAIL PROTECTED] Reported By: butterblume83 at gmx dot de -Status: Open +Status: Feedback Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: Make sure you have yacc/bison installed. Previous Comments: [2006-09-09 20:09:43] butterblume83 at gmx dot de @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. [2006-09-09 19:48:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 19:30:45] butterblume83 at gmx dot de Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Fbk->Opn]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 User updated by: butterblume83 at gmx dot de Reported By: butterblume83 at gmx dot de -Status: Feedback +Status: Open Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: @Johannes: the exact same error with 5.2 snapshot. Btw, the problem does not occur in Slackware 10.2. Previous Comments: [2006-09-09 19:48:06] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip [2006-09-09 19:30:45] butterblume83 at gmx dot de Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [Opn->Fbk]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
ID: 38762 Updated by: [EMAIL PROTECTED] Reported By: butterblume83 at gmx dot de -Status: Open +Status: Feedback Bug Type: Compile Failure Operating System: Ubuntu Dapper Drake PHP Version: 5.1.6 New Comment: Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip Previous Comments: [2006-09-09 19:30:45] butterblume83 at gmx dot de Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit this bug report at http://bugs.php.net/?id=38762&edit=1
#38762 [NEW]: build dir != src dir results in "Zend/zend_language_parser.c: No such file"
From: butterblume83 at gmx dot de Operating system: Ubuntu Dapper Drake PHP version: 5.1.6 PHP Bug Type: Compile Failure Bug description: build dir != src dir results in "Zend/zend_language_parser.c: No such file" Description: When I build PHP and the build directory (from where I call configure) is different to the source directory, I always (configure with or without params) produces the error that zend_language_parser.c was not found. When building from inside the source directory (./configure) is all nice and dandy! Reproduce code: --- cd build ../src/php-5.1.6/configure make Expected result: "Build successfully done." Actual result: -- -I/home/fa/dev/build-area/php5/build/php/ -D_REENTRANT -I/usr/include -g -O2 -pthread -DZTS -c Zend/zend_language_parser.c -o Zend/zend_language_parser.lo gcc: Zend/zend_language_parser.c: No such file or directory gcc: no input files make: *** [Zend/zend_language_parser.lo] Error 1 -- Edit bug report at http://bugs.php.net/?id=38762&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=38762&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=38762&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=38762&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=38762&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=38762&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=38762&r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=38762&r=needscript Try newer version:http://bugs.php.net/fix.php?id=38762&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=38762&r=support Expected behavior:http://bugs.php.net/fix.php?id=38762&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=38762&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=38762&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=38762&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38762&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=38762&r=dst IIS Stability:http://bugs.php.net/fix.php?id=38762&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=38762&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=38762&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=38762&r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=38762&r=mysqlcfg
#38759 [Csd]: PDO sqlite2 empty query causes segfault
ID: 38759 User updated by: jcd+php at psu dot edu Reported By: jcd+php at psu dot edu Status: Closed Bug Type: SQLite related Operating System: Solaris 9 / Ubuntu Linux 6.06 PHP Version: 5.1.6 New Comment: Thanks for committing this. It did seem pretty murky if this was more an SQLite or PHP issue due to the language used for sqlite_step() in the version 2 API docs on http://sqlite.org/c_interface.html, section 2.2. Though, I agree functions should check pointer arguments before dereference. Thanks again! Previous Comments: [2006-09-09 10:59:51] [EMAIL PROTECTED] This is actually SQLite problem, but I agree, a workaround is required. Fixed in 5_2 and HEAD. [2006-09-09 00:50:45] jcd+php at psu dot edu Description: Empty, whitespace and/or comments only query strings passed into the query method of a PDO object for a 'sqlite2' database appear to cause segmentation faults. PDO 'sqlite' (SQLite 3) objects appear immune as does the older sqlite extention (sqlite_query()). The function pdo_sqlite2_stmt_execute() in ext/sqlite/pdo_sqlite2.c does not appear to catch a case when sqlite_compile() returns SQLITE_OK but sets the sqlite virtual machine pointer to NULL. This seems to occur for empty query strings (0 length, whitespace and/or comments). When passed unchecked into sqlite_step(), as it appears to be in pdo_sqlite2_stmt_execute(), sqlite_step() attempts to dereference the pointer, causing a segmentation fault. The equivalent function (sqlite_query()) in ext/sqlite/sqlite.c appears to catch this. This occurs on both: - Solaris 9, Sun Forte Developer 7 C compiler - Ubuntu Linux 6.06, gcc 4.0.3 (Ubuntu 4.0.3-1ubuntu5) Using both PHP versions: - php-5.1.6 - php5.2-200609072030 The shorter configure line (ubuntu) was: ./configure \ --with-apxs2=/usr/bin/apxs2 \ --prefix=/usr/local/php-5.1.6 \ --with-pdo-sqlite \ --with-sqlite \ --with-libxml-dir=/usr I triggered it in both mod_php + Apache (1 and 2) and on the command line. The traces are for the cli. The solaris version had some php.ini customizations, the ubuntu install had none. Reproduce code: --- query(" "); ?> Expected result: Not crash. Either return an error to indicate the fact that the query was empty or do nothing. I found that the patch at http://www.personal.psu.edu/jcd/patches/php-5.1.6_pdo_sqlite2_empty_query.patch fixed the segfaults for me on both platforms I tested. Actual result: -- I can reproduce a segfault with every try. With my patch, I have yet to trigger a crash. solaris9$ pstack /export/cores/core.snail.0.php.14111 core '/export/cores/core.snail.0.php.14111' of 14111: /export/ladmin/phase2.build4/php/bi n/php pdo_sqlite2_bugtest.php 00586430 sqlite_step (0, ff4558, ff4550, ff4554, ffbfe87c, 11828) + 40 00541e64 pdo_sqlite2_stmt_execute (ff0e08, d475d8, ff0e5c, 3000, 3000, 0) + 1b4 003f789c zif_PDO_query (1, feceb8, 0, fece68, 0, 0) + 31c 0086397c zend_do_fcall_common_helper_SPEC (ffbfebb0, fece90, 5, 0, 0, 0) + 5cc 00864238 ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER (ffbfebb0, 0, , 5, 0, ffbfea85) + 38 00863220 execute (feeb60, f00d50, 4e, ffbfecf4, 4, 0) + 2c8 008064ac zend_execute_scripts (8, 0, 3, 0, ffbff3b0, 0) + 1cc 00732244 php_execute_script (ffbff3b0, d70819, ffbff36c, 0, 70, 2d) + 3c4 008e2b48 main (2, ffbff444, ffbff450, da2400, 0, 0) + 1580 001e06c8 _start (0, 0, 0, 0, 0, 0) + 108 ubuntu6.06$ gdb /usr/local/php-5.1.6/bin/php core GNU gdb 6.4-debian Copyright 2005 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i486-linux-gnu"...Using host libthread_db library "/lib/tls/i68 6/cmov/libthread_db.so.1". Core was generated by `/usr/local/php-5.1.6/bin/php -r $h=new PDO("sqlite2:db/sqlite.db");$ h->query("'. Program terminated with signal 11, Segmentation fault. warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...done. Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1 Reading symbols from /lib/tls/i686/cmov/librt.so.1...done. Loaded symbols for /lib/tls/i686/cmov/librt.so.1 Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...done. Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2 Reading symbols from /lib/tls/i686/cmov/libm.so.6...done. Loaded symbols for /lib/tls/i686/cmov/libm.so.6 Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...done. Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib
#38760 [Fbk->Opn]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 User updated by: aireater at gmail dot com Reported By: aireater at gmail dot com -Status: Feedback +Status: Open Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: This is a sample script to reproduce the issue. Create a table with a "name" column of a varchar type only before testing. The string "DD" means the string is consisted of multi-byte UTF-8 cahracters. Some are inserted correctly, but most of time, inserted strings are not correctly shown on the screen because they are not correctly inserted in UCS-2. This script is for MS SQL Server 2005 Express. \n";} mssql_close($sqlconnect); ?> Previous Comments: [2006-09-09 12:12:25] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. [2006-09-09 12:04:30] aireater at gmail dot com Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. [2006-09-09 10:39:29] [EMAIL PROTECTED] Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. [2006-09-09 01:30:35] aireater at gmail dot com Description: On PHP 5.1.6 Windows binary with php_mbstring and php_mssql.dll enabled, it fails to convert multi-byte UTF-8 strings to UCS-2 srtings. I've tried MS SQL Server 2005 Express and Standard but no success. On Windows 2003 Server. I've also tried several ntwdblib.dll but in vain. Expected result: Should correctly convert multi-byte UTF-8 strings to UCS-2. Actual result: -- Most of single byte UTF-8 strings seem to be stored in the database but most of multi-byte UTF-8 strings get garbage. -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#37726 [Opn->Bgs]: proc_open let fd opened in the child process
ID: 37726 Updated by: [EMAIL PROTECTED] Reported By: n dot escuder at intra-links dot com -Status: Open +Status: Bogus Bug Type: Program Execution Operating System: Linux PHP Version: 5.1.4 New Comment: Please read what [EMAIL PROTECTED] said. No bug here. Previous Comments: [2006-09-09 13:30:22] n dot escuder at intra-links dot com Hello, When we create a child process on unix with fork and execl as php does in proc_open we must cleanup all open fd execpt 0 1 2 before call execl to have a clean child. I think this is a bug because if in a script you open an sqlite query ex: update ... and you start a proc_open the proc_open will have the fd to the db dans the parent process will have a lock on the database. Any childs process must not herit the parent fd's ! I use php cli version and start a lot of process system from an php script parent and all child get all fd's from the parent ( connection to database, files opened ... ). This is not clean because all process are new process started by proc_open and not pcntl_fork. See You. Escuder Nicolas PS: I'm french so sorry for the traduction ;) [2006-09-08 20:57:50] [EMAIL PROTECTED] Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php [2006-06-26 07:55:39] n dot escuder at intra-links dot com This is not the same in the bug #34794 the patch i see is only for new opened descriptor and not all opened descriptor ( databases connections ... ). In proc_open you use fork for creating a new child and change de descriptor of STDIN STDOUT STDERR and after you do an exec. Just before doing the exec you must close all open descriptor greater than STDERR. [2006-06-25 17:51:36] jdolecek at NetBSD dot org This may be the same problem as Bug #34794, which includes the fix. [2006-06-07 17:08:45] n dot escuder at intra-links dot com Yes when we do a pcntl_fork or a fork in C the FD must stay open but here it's a complety new program that is started. Proc_open use fork for starting the new process but don't cleanup open descriptor after the fork. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/37726 -- Edit this bug report at http://bugs.php.net/?id=37726&edit=1
#38760 [Opn->Bgs]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 Updated by: [EMAIL PROTECTED] Reported By: aireater at gmail dot com -Status: Open +Status: Bogus Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Due to the volume of reports we can not explain in detail here why your report is not a bug. The support channels will be able to provide an explanation for you. Thank you for your interest in PHP. Previous Comments: [2006-09-09 13:38:29] aireater at gmail dot com Could you replace the prior sample with this one? The old one has some authentification info. \n";} mssql_close($sqlconnect); ?> [2006-09-09 13:31:16] aireater at gmail dot com In the prior sample, the mbstring was used just to set the mb_internal_encoding to UTF-8 in php.ini. In another case as below in which I converted a string from UTF-8 to UCS2 before inserted but it did not work either. I'm not sure and I don't care which func should correctly convert a string to UCS2. I just want to insert a multi-byte unicode string to MS SQL Server. \n";} mssql_close($sqlconnect); ?> [2006-09-09 13:11:22] [EMAIL PROTECTED] What makes you think that this code should convert something to UCS-2? What does it have to do with mbstring, which is even not mentioned in this code? [2006-09-09 13:04:57] aireater at gmail dot com This is a sample script to reproduce the issue. Create a table with a "name" column of a varchar type only before testing. The string "DD" means the string is consisted of multi-byte UTF-8 cahracters. Some are inserted correctly, but most of time, inserted strings are not correctly shown on the screen because they are not correctly inserted in UCS-2. This script is for MS SQL Server 2005 Express. \n";} mssql_close($sqlconnect); ?> [2006-09-09 12:12:25] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38760 -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#38760 [Opn]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 User updated by: aireater at gmail dot com Reported By: aireater at gmail dot com Status: Open Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: Could you replace the prior sample with this one? The old one has some authentification info. \n";} mssql_close($sqlconnect); ?> Previous Comments: [2006-09-09 13:31:16] aireater at gmail dot com In the prior sample, the mbstring was used just to set the mb_internal_encoding to UTF-8 in php.ini. In another case as below in which I converted a string from UTF-8 to UCS2 before inserted but it did not work either. I'm not sure and I don't care which func should correctly convert a string to UCS2. I just want to insert a multi-byte unicode string to MS SQL Server. \n";} mssql_close($sqlconnect); ?> [2006-09-09 13:11:22] [EMAIL PROTECTED] What makes you think that this code should convert something to UCS-2? What does it have to do with mbstring, which is even not mentioned in this code? [2006-09-09 13:04:57] aireater at gmail dot com This is a sample script to reproduce the issue. Create a table with a "name" column of a varchar type only before testing. The string "DD" means the string is consisted of multi-byte UTF-8 cahracters. Some are inserted correctly, but most of time, inserted strings are not correctly shown on the screen because they are not correctly inserted in UCS-2. This script is for MS SQL Server 2005 Express. \n";} mssql_close($sqlconnect); ?> [2006-09-09 12:12:25] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. [2006-09-09 12:04:30] aireater at gmail dot com Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38760 -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#38760 [Fbk->Opn]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 User updated by: aireater at gmail dot com Reported By: aireater at gmail dot com -Status: Feedback +Status: Open Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: In the prior sample, the mbstring was used just to set the mb_internal_encoding to UTF-8 in php.ini. In another case as below in which I converted a string from UTF-8 to UCS2 before inserted but it did not work either. I'm not sure and I don't care which func should correctly convert a string to UCS2. I just want to insert a multi-byte unicode string to MS SQL Server. \n";} mssql_close($sqlconnect); ?> Previous Comments: [2006-09-09 13:11:22] [EMAIL PROTECTED] What makes you think that this code should convert something to UCS-2? What does it have to do with mbstring, which is even not mentioned in this code? [2006-09-09 13:04:57] aireater at gmail dot com This is a sample script to reproduce the issue. Create a table with a "name" column of a varchar type only before testing. The string "DD" means the string is consisted of multi-byte UTF-8 cahracters. Some are inserted correctly, but most of time, inserted strings are not correctly shown on the screen because they are not correctly inserted in UCS-2. This script is for MS SQL Server 2005 Express. \n";} mssql_close($sqlconnect); ?> [2006-09-09 12:12:25] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. [2006-09-09 12:04:30] aireater at gmail dot com Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. [2006-09-09 10:39:29] [EMAIL PROTECTED] Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/38760 -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#37726 [Bgs->Opn]: proc_open let fd opened in the child process
ID: 37726 User updated by: n dot escuder at intra-links dot com Reported By: n dot escuder at intra-links dot com -Status: Bogus +Status: Open Bug Type: Program Execution Operating System: Linux PHP Version: 5.1.4 New Comment: Hello, When we create a child process on unix with fork and execl as php does in proc_open we must cleanup all open fd execpt 0 1 2 before call execl to have a clean child. I think this is a bug because if in a script you open an sqlite query ex: update ... and you start a proc_open the proc_open will have the fd to the db dans the parent process will have a lock on the database. Any childs process must not herit the parent fd's ! I use php cli version and start a lot of process system from an php script parent and all child get all fd's from the parent ( connection to database, files opened ... ). This is not clean because all process are new process started by proc_open and not pcntl_fork. See You. Escuder Nicolas PS: I'm french so sorry for the traduction ;) Previous Comments: [2006-09-08 20:57:50] [EMAIL PROTECTED] Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php [2006-06-26 07:55:39] n dot escuder at intra-links dot com This is not the same in the bug #34794 the patch i see is only for new opened descriptor and not all opened descriptor ( databases connections ... ). In proc_open you use fork for creating a new child and change de descriptor of STDIN STDOUT STDERR and after you do an exec. Just before doing the exec you must close all open descriptor greater than STDERR. [2006-06-25 17:51:36] jdolecek at NetBSD dot org This may be the same problem as Bug #34794, which includes the fix. [2006-06-07 17:08:45] n dot escuder at intra-links dot com Yes when we do a pcntl_fork or a fork in C the FD must stay open but here it's a complety new program that is started. Proc_open use fork for starting the new process but don't cleanup open descriptor after the fork. [2006-06-07 15:16:24] [EMAIL PROTECTED] IMHO, I think this is expected. When you fork under unix the open file descriptors will be copied to the child process. proc_open just enforces what the specified fd should look like. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/37726 -- Edit this bug report at http://bugs.php.net/?id=37726&edit=1
#38760 [Opn->Fbk]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 Updated by: [EMAIL PROTECTED] Reported By: aireater at gmail dot com -Status: Open +Status: Feedback Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: What makes you think that this code should convert something to UCS-2? What does it have to do with mbstring, which is even not mentioned in this code? Previous Comments: [2006-09-09 13:04:57] aireater at gmail dot com This is a sample script to reproduce the issue. Create a table with a "name" column of a varchar type only before testing. The string "DD" means the string is consisted of multi-byte UTF-8 cahracters. Some are inserted correctly, but most of time, inserted strings are not correctly shown on the screen because they are not correctly inserted in UCS-2. This script is for MS SQL Server 2005 Express. \n";} mssql_close($sqlconnect); ?> [2006-09-09 12:12:25] [EMAIL PROTECTED] Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. [2006-09-09 12:04:30] aireater at gmail dot com Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. [2006-09-09 10:39:29] [EMAIL PROTECTED] Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. [2006-09-09 01:30:35] aireater at gmail dot com Description: On PHP 5.1.6 Windows binary with php_mbstring and php_mssql.dll enabled, it fails to convert multi-byte UTF-8 strings to UCS-2 srtings. I've tried MS SQL Server 2005 Express and Standard but no success. On Windows 2003 Server. I've also tried several ntwdblib.dll but in vain. Expected result: Should correctly convert multi-byte UTF-8 strings to UCS-2. Actual result: -- Most of single byte UTF-8 strings seem to be stored in the database but most of multi-byte UTF-8 strings get garbage. -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#38760 [Opn->Fbk]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 Updated by: [EMAIL PROTECTED] Reported By: aireater at gmail dot com -Status: Open +Status: Feedback Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: Thank you for this bug report. To properly diagnose the problem, we need a short but complete example script to be able to reproduce this bug ourselves. A proper reproducing script starts with , is max. 10-20 lines long and does not require any external resources such as databases, etc. If the script requires a database to demonstrate the issue, please make sure it creates all necessary tables, stored procedures etc. Please avoid embedding huge scripts into the report. Previous Comments: [2006-09-09 12:04:30] aireater at gmail dot com Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. [2006-09-09 10:39:29] [EMAIL PROTECTED] Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. [2006-09-09 01:30:35] aireater at gmail dot com Description: On PHP 5.1.6 Windows binary with php_mbstring and php_mssql.dll enabled, it fails to convert multi-byte UTF-8 strings to UCS-2 srtings. I've tried MS SQL Server 2005 Express and Standard but no success. On Windows 2003 Server. I've also tried several ntwdblib.dll but in vain. Expected result: Should correctly convert multi-byte UTF-8 strings to UCS-2. Actual result: -- Most of single byte UTF-8 strings seem to be stored in the database but most of multi-byte UTF-8 strings get garbage. -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#38760 [Fbk->Opn]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 User updated by: aireater at gmail dot com Reported By: aireater at gmail dot com -Status: Feedback +Status: Open Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: Set mb_internal_encoding to UTF-8, and send an INSERT statement, that inserts a multi-byte string in UTF-8 to a varchar culumn, then an inserted string get garbage. It's not converted to UCS-2 that MS SQL Server supports to store an unicode string. Previous Comments: [2006-09-09 10:39:29] [EMAIL PROTECTED] Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. [2006-09-09 01:30:35] aireater at gmail dot com Description: On PHP 5.1.6 Windows binary with php_mbstring and php_mssql.dll enabled, it fails to convert multi-byte UTF-8 strings to UCS-2 srtings. I've tried MS SQL Server 2005 Express and Standard but no success. On Windows 2003 Server. I've also tried several ntwdblib.dll but in vain. Expected result: Should correctly convert multi-byte UTF-8 strings to UCS-2. Actual result: -- Most of single byte UTF-8 strings seem to be stored in the database but most of multi-byte UTF-8 strings get garbage. -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1
#38759 [Opn->Csd]: PDO sqlite2 empty query causes segfault
ID: 38759 Updated by: [EMAIL PROTECTED] Reported By: jcd+php at psu dot edu -Status: Open +Status: Closed Bug Type: SQLite related Operating System: Solaris 9 / Ubuntu Linux 6.06 PHP Version: 5.1.6 New Comment: This is actually SQLite problem, but I agree, a workaround is required. Fixed in 5_2 and HEAD. Previous Comments: [2006-09-09 00:50:45] jcd+php at psu dot edu Description: Empty, whitespace and/or comments only query strings passed into the query method of a PDO object for a 'sqlite2' database appear to cause segmentation faults. PDO 'sqlite' (SQLite 3) objects appear immune as does the older sqlite extention (sqlite_query()). The function pdo_sqlite2_stmt_execute() in ext/sqlite/pdo_sqlite2.c does not appear to catch a case when sqlite_compile() returns SQLITE_OK but sets the sqlite virtual machine pointer to NULL. This seems to occur for empty query strings (0 length, whitespace and/or comments). When passed unchecked into sqlite_step(), as it appears to be in pdo_sqlite2_stmt_execute(), sqlite_step() attempts to dereference the pointer, causing a segmentation fault. The equivalent function (sqlite_query()) in ext/sqlite/sqlite.c appears to catch this. This occurs on both: - Solaris 9, Sun Forte Developer 7 C compiler - Ubuntu Linux 6.06, gcc 4.0.3 (Ubuntu 4.0.3-1ubuntu5) Using both PHP versions: - php-5.1.6 - php5.2-200609072030 The shorter configure line (ubuntu) was: ./configure \ --with-apxs2=/usr/bin/apxs2 \ --prefix=/usr/local/php-5.1.6 \ --with-pdo-sqlite \ --with-sqlite \ --with-libxml-dir=/usr I triggered it in both mod_php + Apache (1 and 2) and on the command line. The traces are for the cli. The solaris version had some php.ini customizations, the ubuntu install had none. Reproduce code: --- query(" "); ?> Expected result: Not crash. Either return an error to indicate the fact that the query was empty or do nothing. I found that the patch at http://www.personal.psu.edu/jcd/patches/php-5.1.6_pdo_sqlite2_empty_query.patch fixed the segfaults for me on both platforms I tested. Actual result: -- I can reproduce a segfault with every try. With my patch, I have yet to trigger a crash. solaris9$ pstack /export/cores/core.snail.0.php.14111 core '/export/cores/core.snail.0.php.14111' of 14111: /export/ladmin/phase2.build4/php/bi n/php pdo_sqlite2_bugtest.php 00586430 sqlite_step (0, ff4558, ff4550, ff4554, ffbfe87c, 11828) + 40 00541e64 pdo_sqlite2_stmt_execute (ff0e08, d475d8, ff0e5c, 3000, 3000, 0) + 1b4 003f789c zif_PDO_query (1, feceb8, 0, fece68, 0, 0) + 31c 0086397c zend_do_fcall_common_helper_SPEC (ffbfebb0, fece90, 5, 0, 0, 0) + 5cc 00864238 ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER (ffbfebb0, 0, , 5, 0, ffbfea85) + 38 00863220 execute (feeb60, f00d50, 4e, ffbfecf4, 4, 0) + 2c8 008064ac zend_execute_scripts (8, 0, 3, 0, ffbff3b0, 0) + 1cc 00732244 php_execute_script (ffbff3b0, d70819, ffbff36c, 0, 70, 2d) + 3c4 008e2b48 main (2, ffbff444, ffbff450, da2400, 0, 0) + 1580 001e06c8 _start (0, 0, 0, 0, 0, 0) + 108 ubuntu6.06$ gdb /usr/local/php-5.1.6/bin/php core GNU gdb 6.4-debian Copyright 2005 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "i486-linux-gnu"...Using host libthread_db library "/lib/tls/i68 6/cmov/libthread_db.so.1". Core was generated by `/usr/local/php-5.1.6/bin/php -r $h=new PDO("sqlite2:db/sqlite.db");$ h->query("'. Program terminated with signal 11, Segmentation fault. warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/tls/i686/cmov/libcrypt.so.1...done. Loaded symbols for /lib/tls/i686/cmov/libcrypt.so.1 Reading symbols from /lib/tls/i686/cmov/librt.so.1...done. Loaded symbols for /lib/tls/i686/cmov/librt.so.1 Reading symbols from /lib/tls/i686/cmov/libresolv.so.2...done. Loaded symbols for /lib/tls/i686/cmov/libresolv.so.2 Reading symbols from /lib/tls/i686/cmov/libm.so.6...done. Loaded symbols for /lib/tls/i686/cmov/libm.so.6 Reading symbols from /lib/tls/i686/cmov/libnsl.so.1...done. Loaded symbols for /lib/tls/i686/cmov/libnsl.so.1 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib/libz.so.1 Reading symbols from /usr/lib/libxml2.so.2...done. Loaded symbols for /usr/lib/libxml2.so.2 Reading symbols from /lib/tls/i686/cmov/libdl.so.2...done. Loaded symbols for /lib/tls/i686/cmov/libdl.so.2 Reading symbols from /lib/tls/i686/cmov/libpthread.so.0...done. Loaded symbols for /lib/tls/i686/cmov/libpthread.so.0 Reading symbols from /lib/tls/i686/cmov/libc.so.6...done. Loaded symbols for /
#38758 [Opn->Bgs]: fseek returns false if offset is over 10GB (10737418239 bytes)
ID: 38758 Updated by: [EMAIL PROTECTED] Reported By: geoffrey at google dot com -Status: Open +Status: Bogus Bug Type: Filesystem function related Operating System: Redhat Linux 2.4.22 PHP Version: 5.1.6 New Comment: Integer is still limited, even if you use _FILE_OFFSET_BITS. Previous Comments: [2006-09-09 06:27:11] judas dot iscariote at gmail dot com AFAIK, LFS support is not working properly and IIRC last time I saw developer response, this is scheduled to be fixed only in PHP6. somebody can correct me If I wrong. [2006-09-09 00:42:57] geoffrey at google dot com Description: fseek returns false if offset is over 10GB (10737418239 bytes). This could be an underlying problem with llseek. I'm running php 5.1.6. my config line: CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" ./configure Using stock php.ini-dist Reproduce code: --- #!/usr/local/src/php-5.1.6/sapi/cli/php -q ... lstat64("bigfile", {st_mode=S_IFREG|0666, st_size=20304186228, ...}) = 0 open("bigfile", O_RDONLY|O_LARGEFILE) = 3 fstat64(3, {st_mode=S_IFREG|0666, st_size=20304186228, ...}) = 0 _llseek(3, 0, [0], SEEK_CUR)= 0 _llseek(3, 2147483647, [2147483647], SEEK_SET) = 0 read(3, ""..., 8192) = 8192 write(1, ""..., 37, ) = 37 write(1, "-2147483612", 11-2147483612) = 11 _llseek(3, 0, [0], SEEK_SET)= 0 _llseek(3, 18446744071562067968, 0xbfffcdf0, SEEK_SET) = -1 EINVAL (Invalid argument) read(3, ""..., 8192) = 8192 write(1, ""..., 54 ) = 54 write(1, "54", 254) = 2 close(3)= 0 close(0) ... Geoff -- Edit this bug report at http://bugs.php.net/?id=38758&edit=1
#38760 [Opn->Fbk]: php_mssql fails to convert multi-byte UTF-8 to UCS-2
ID: 38760 Updated by: [EMAIL PROTECTED] Reported By: aireater at gmail dot com -Status: Open +Status: Feedback Bug Type: MSSQL related Operating System: Windows 2003 Server PHP Version: 5.1.6 New Comment: Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. Previous Comments: [2006-09-09 01:30:35] aireater at gmail dot com Description: On PHP 5.1.6 Windows binary with php_mbstring and php_mssql.dll enabled, it fails to convert multi-byte UTF-8 strings to UCS-2 srtings. I've tried MS SQL Server 2005 Express and Standard but no success. On Windows 2003 Server. I've also tried several ntwdblib.dll but in vain. Expected result: Should correctly convert multi-byte UTF-8 strings to UCS-2. Actual result: -- Most of single byte UTF-8 strings seem to be stored in the database but most of multi-byte UTF-8 strings get garbage. -- Edit this bug report at http://bugs.php.net/?id=38760&edit=1