[PHP-CVS] svn: /php/php-src/branches/PHP_5_2/ext/zip/tests/ bug38943.phpt

2009-07-27 Thread Rasmus Lerdorf
rasmus   Mon, 27 Jul 2009 23:37:40 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286433

Log:
The version check was completely bogus in this test

Changed paths:
U   php/php-src/branches/PHP_5_2/ext/zip/tests/bug38943.phpt

Modified: php/php-src/branches/PHP_5_2/ext/zip/tests/bug38943.phpt
===
--- php/php-src/branches/PHP_5_2/ext/zip/tests/bug38943.phpt2009-07-27 
23:23:39 UTC (rev 286432)
+++ php/php-src/branches/PHP_5_2/ext/zip/tests/bug38943.phpt2009-07-27 
23:37:40 UTC (rev 286433)
@@ -3,8 +3,9 @@
 --SKIPIF--
 2) die('skip');
 ?>
 --FILE--
 -- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/branches/PHP_5_2/ext/iconv/tests/ iconv_stream_filter_delimiter.phpt

2009-07-27 Thread Rasmus Lerdorf
rasmus   Mon, 27 Jul 2009 23:08:23 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286431

Log:
We don't support . as a delimiter here in PHP 5.2.  Support was added in 5.3

Changed paths:
U   
php/php-src/branches/PHP_5_2/ext/iconv/tests/iconv_stream_filter_delimiter.phpt

Modified: 
php/php-src/branches/PHP_5_2/ext/iconv/tests/iconv_stream_filter_delimiter.phpt
===
--- 
php/php-src/branches/PHP_5_2/ext/iconv/tests/iconv_stream_filter_delimiter.phpt 
2009-07-27 22:12:35 UTC (rev 286430)
+++ 
php/php-src/branches/PHP_5_2/ext/iconv/tests/iconv_stream_filter_delimiter.phpt 
2009-07-27 23:08:23 UTC (rev 286431)
@@ -40,10 +40,12 @@
 string(20) "a4b3a4f3a4cba4c1a4cf"
 string(10) "69636f6e76"
 string(2) "0a"
-string(20) "a4b3a4f3a4cba4c1a4cf"
-string(10) "69636f6e76"
-string(2) "0a"

+Warning: stream_filter_append(): unable to create or locate filter 
"convert.iconv.ISO-2022-JP.EUC-JP" in %s/iconv_stream_filter_delimiter.php on 
line %d
+string(20) "1b244224332473244b24"
+string(10) "41244f1b28"
+string(2) "42"
+
 Warning: stream_filter_append(): unable to create or locate filter 
"convert.iconv.ISO-2022-JP\0EUC-JP" in %s/iconv_stream_filter_delimiter.php on 
line %d
 string(20) "1b244224332473244b24"
 string(10) "41244f1b28"

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/branches/PHP_5_2/ext/gd/tests/ bug43073.phpt

2009-07-27 Thread Takeshi Abe
tabe Mon, 27 Jul 2009 22:12:35 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286430

Log:
MFB: added test for #43073

Bug: http://bugs.php.net/43073 (Closed) TrueType bounding box is wrong for 
angle<>0
  
Changed paths:
A   php/php-src/branches/PHP_5_2/ext/gd/tests/bug43073.phpt

Added: php/php-src/branches/PHP_5_2/ext/gd/tests/bug43073.phpt
===
--- php/php-src/branches/PHP_5_2/ext/gd/tests/bug43073.phpt 
(rev 0)
+++ php/php-src/branches/PHP_5_2/ext/gd/tests/bug43073.phpt 2009-07-27 
22:12:35 UTC (rev 286430)
@@ -0,0 +1,46 @@
+--TEST--
+Bug #43073 (TrueType bounding box is wrong for angle<>0)
+--SKIPIF--
+
+--FILE--
+
+--EXPECTF--
+(500, 402), (610, 402), (610, 376), (500, 376)
+(492, 363), (591, 322), (580, 295), (480, 336)
+(470, 331), (548, 254), (527, 233), (449, 310)
+(439, 309), (483, 202), (461, 193), (416, 299)
+(401, 300), (401, 183), (381, 183), (381, 300)
+(362, 307), (316, 195), (291, 205), (337, 318)
+(330, 329), (246, 244), (224, 265), (308, 350)
+(308, 360), (202, 316), (190, 344), (296, 388)
+(300, 399), (186, 399), (186, 425), (300, 425)
+(306, 437), (195, 483), (206, 510), (318, 464)
+(328, 469), (240, 557), (260, 578), (349, 491)
+(359, 491), (312, 607), (334, 616), (382, 501)
+(398, 500), (398, 618), (418, 618), (418, 500)
+(436, 493), (483, 607), (507, 597), (461, 482)
+(468, 471), (555, 558), (577, 538), (490, 450)
+(490, 440), (600, 485), (611, 457), (502, 412)

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/branches/PHP_5_3/ext/gd/tests/ bug43073.phpt

2009-07-27 Thread Takeshi Abe
tabe Mon, 27 Jul 2009 22:11:43 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286429

Log:
added test for #43073

Bug: http://bugs.php.net/43073 (Closed) TrueType bounding box is wrong for 
angle<>0
  
Changed paths:
A   php/php-src/branches/PHP_5_3/ext/gd/tests/bug43073.phpt

Added: php/php-src/branches/PHP_5_3/ext/gd/tests/bug43073.phpt
===
--- php/php-src/branches/PHP_5_3/ext/gd/tests/bug43073.phpt 
(rev 0)
+++ php/php-src/branches/PHP_5_3/ext/gd/tests/bug43073.phpt 2009-07-27 
22:11:43 UTC (rev 286429)
@@ -0,0 +1,46 @@
+--TEST--
+Bug #43073 (TrueType bounding box is wrong for angle<>0)
+--SKIPIF--
+
+--FILE--
+
+--EXPECTF--
+(500, 402), (610, 402), (610, 376), (500, 376)
+(492, 363), (591, 322), (580, 295), (480, 336)
+(470, 331), (548, 254), (527, 233), (449, 310)
+(439, 309), (483, 202), (461, 193), (416, 299)
+(401, 300), (401, 183), (381, 183), (381, 300)
+(362, 307), (316, 195), (291, 205), (337, 318)
+(330, 329), (246, 244), (224, 265), (308, 350)
+(308, 360), (202, 316), (190, 344), (296, 388)
+(300, 399), (186, 399), (186, 425), (300, 425)
+(306, 437), (195, 483), (206, 510), (318, 464)
+(328, 469), (240, 557), (260, 578), (349, 491)
+(359, 491), (312, 607), (334, 616), (382, 501)
+(398, 500), (398, 618), (418, 618), (418, 500)
+(436, 493), (483, 607), (507, 597), (461, 482)
+(468, 471), (555, 558), (577, 538), (490, 450)
+(490, 440), (600, 485), (611, 457), (502, 412)

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/trunk/ext/exif/ exif.c

2009-07-27 Thread Ilia Alshanetsky
iliaaMon, 27 Jul 2009 19:36:55 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286426

Log:
Fixed compiler warning

Changed paths:
U   php/php-src/trunk/ext/exif/exif.c

Modified: php/php-src/trunk/ext/exif/exif.c
===
--- php/php-src/trunk/ext/exif/exif.c   2009-07-27 18:15:14 UTC (rev 286425)
+++ php/php-src/trunk/ext/exif/exif.c   2009-07-27 19:36:55 UTC (rev 286426)
@@ -3893,7 +3893,7 @@
image_info_type ImageInfo;
char tmp[64], *sections_str = NULL, *p_sections_needed = NULL, *s;
char *filename;
-   int filename_len, sections_str_len = 0;
+   int filename_len;

if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Z|sbb", &p_name, 
&p_sections_needed, &p_sections_needed_len, &sub_arrays, &read_thumbnail) == 
FAILURE) {
return;

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /SVNROOT/ commit-email.php

2009-07-27 Thread Gwynne Raskind
gwynne   Mon, 27 Jul 2009 18:15:14 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286425

Log:
pear_avail commits should go to pear lists, and no need for sending SVNROOT 
commits to svn-migration anymore

Changed paths:
U   SVNROOT/commit-email.php

Modified: SVNROOT/commit-email.php
===
--- SVNROOT/commit-email.php2009-07-27 17:51:08 UTC (rev 286424)
+++ SVNROOT/commit-email.php2009-07-27 18:15:14 UTC (rev 286425)
@@ -96,7 +96,8 @@

 // Internals
 '|^systems|' => array('syst...@php.net'),
-'|^SVNROOT|' => array('svn-migrat...@lists.php.net', 
'php-cvs@lists.php.net'),
+'|^SVNROOT/pear_avail|' => array('pear-...@lists.php.net', 
'pear-c...@lists.php.net'),
+'|^SVNROOT|' => array('php-cvs@lists.php.net'),
 );
 $fallback_addresses = array('php-cvs@lists.php.net');
 $always_addresses = array('gwy...@php.net');

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /SVNROOT/ header.ezt header.ezt.README

2009-07-27 Thread Rasmus Lerdorf
rasmus   Mon, 27 Jul 2009 17:51:08 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286424

Log:
The svn.php.net styling

Changed paths:
A   SVNROOT/header.ezt
A   SVNROOT/header.ezt.README

Added: SVNROOT/header.ezt
===
--- SVNROOT/header.ezt  (rev 0)
+++ SVNROOT/header.ezt  2009-07-27 17:51:08 UTC (rev 286424)
@@ -0,0 +1,42 @@
+http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
+http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en">
+
+  [if-any rootname][[][rootname]][else]ViewVC[end] [page_title]
+  
+  
+  http://static.php.net/www.php.net/styles/site.css"; />
+  http://static.php.net/www.php.net/styles/phpnet.css"; />
+  http://static.php.net/www.php.net/favicon.ico"; />
+  
+.paddinghack { margin-left: 5px; margin-top: 5px; }
+  
+  [if-any rss_href][end]
+
+
+
+
+ 
+  http://static.php.net/www.php.net/images/php.gif"; alt="PHP" width="120" 
height="67" hspace="3" />
+   
+ 
+ 
+  
+ http://www.php.net/svn.php";>SVN 
Instructions  
+  
+ 
+ 
+   [if-any roots_href]/[else]/[end][if-any nav_path][for nav_path][if-any 
nav_path.href][end][if-index nav_path 
first][[][nav_path.name]][else][nav_path.name][end][if-any 
nav_path.href][end][if-index nav_path last][else]/[end][end][end]
+   
+Main trees: PHP 5.2 |
+PHP 5.3 |
+PHP 6 |
+pecl |
+pear |
+pear-core  
+   
+ 
+
+
+
+

Added: SVNROOT/header.ezt.README
===
--- SVNROOT/header.ezt.README   (rev 0)
+++ SVNROOT/header.ezt.README   2009-07-27 17:51:08 UTC (rev 286424)
@@ -0,0 +1,2 @@
+header.ezt contains the PHP-styling for viewvc on http://svn.php.net
+This file lives in /home/svn/viewvc-svn/templates/include

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /SVNROOT/ pear_avail

2009-07-27 Thread Brett Bieber
saltybeagle  Mon, 27 Jul 2009 15:30:47 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286420

Log:
Correct username - s/bbieber/saltybeagle/

Changed paths:
U   SVNROOT/pear_avail

Modified: SVNROOT/pear_avail
===
--- SVNROOT/pear_avail  2009-07-27 15:29:27 UTC (rev 286419)
+++ SVNROOT/pear_avail  2009-07-27 15:30:47 UTC (rev 286420)
@@ -162,7 +162,7 @@
 avail|kwilms|pear/packages/Crypt_MicroID
 avail|lucor|pear/packages/Net_Nmap
 avail|tetsuya|pear/packages/Services_Yahoo_JP
-avail|bbieber|pear/packages/Structures_Graph
+avail|saltybeagle|pear/packages/Structures_Graph
 
avail|cbrunet|pear/packages/HTML_Entities,pear/packages/File_Sitemap,pear/packages/File_Archive
 avail|baptiste750|pear/packages/PHP_UML,pear/peardoc
 avail|ashiro|pear/packages/Net_AsteriskManager

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /SVNROOT/ pear_avail

2009-07-27 Thread Brett Bieber
saltybeagle  Mon, 27 Jul 2009 15:29:27 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286419

Log:
Grant till karma for pear/packages/Services_ProjectHoneyPot, consolidate all 
his lines and alphabetize

Changed paths:
U   SVNROOT/pear_avail

Modified: SVNROOT/pear_avail
===
--- SVNROOT/pear_avail  2009-07-27 15:24:54 UTC (rev 286418)
+++ SVNROOT/pear_avail  2009-07-27 15:29:27 UTC (rev 286419)
@@ -137,7 +137,7 @@
 avail|patchworker|pear/packages/Text_Wiki
 avail|c0il|pear/packages/PHP_Debug,pear/peardoc
 avail|dw31415|pear/packages/Structures_DataGrid_DataSource_SQLQuery
-avail|till|pear/packages/Contact_Vcard_Build,pear/packages/Contact_Vcard_Parse,pear/packages/Net_CheckIP2,pear/packages/HTTP_Session2
+avail|till|pear/packages/Contact_Vcard_Build,pear/packages/Contact_Vcard_Parse,pear/packages/File_IMC,pear/packages/HTTP_Session2,pear/packages/Mail_Queue,pear/packages/Net_CheckIP2,pear/packages/Services_ProjectHoneyPot
 avail|sprice|pear/peardoc,pear/packages/HTML_BBCodeParser
 avail|onur|pear/peardoc/tr
 avail|cybot|pear/packages/SQL_Parser
@@ -162,7 +162,6 @@
 avail|kwilms|pear/packages/Crypt_MicroID
 avail|lucor|pear/packages/Net_Nmap
 avail|tetsuya|pear/packages/Services_Yahoo_JP
-avail|till|pear/packages/Mail_Queue
 avail|bbieber|pear/packages/Structures_Graph
 
avail|cbrunet|pear/packages/HTML_Entities,pear/packages/File_Sitemap,pear/packages/File_Archive
 avail|baptiste750|pear/packages/PHP_UML,pear/peardoc
@@ -171,7 +170,6 @@
 avail|blindman|pear/packages/Text_Highlighter
 avail|shimooka|pear/packages/Date_Holidays
 avail|hm2k|pear/packages/PHP_Compat
-avail|till|pear/packages/File_IMC
 avail|lucor|pear/packages/Services_Atlassian_Crowd
 avail|kvz|pear/packages/System_Daemon,pear/peardoc
 avail|saltybeagle|pear/installphars

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/branches/PHP_5_2/ NEWS ext/gd/libgd/gdft.c ext/gd/tests/bug48555.phpt ext/gd/tests/bug48732.phpt ext/gd/tests/bug48801.phpt

2009-07-27 Thread Takeshi Abe
tabe Mon, 27 Jul 2009 15:11:46 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286417

Log:
MFH: fixed #48732 (TTF Bounding box wrong for letters below baseline) and 
#48801 (Problem with imagettfbbox)

Bugs: http://bugs.php.net/48732 (Assigned) TTF Bounding box wrong for letters 
below baseline
  http://bugs.php.net/48801 (Open) Problem with imagettfbbox
  
Changed paths:
U   php/php-src/branches/PHP_5_2/NEWS
U   php/php-src/branches/PHP_5_2/ext/gd/libgd/gdft.c
U   php/php-src/branches/PHP_5_2/ext/gd/tests/bug48555.phpt
A   php/php-src/branches/PHP_5_2/ext/gd/tests/bug48732.phpt
A   php/php-src/branches/PHP_5_2/ext/gd/tests/bug48801.phpt

Modified: php/php-src/branches/PHP_5_2/NEWS
===
--- php/php-src/branches/PHP_5_2/NEWS   2009-07-27 15:06:28 UTC (rev 286416)
+++ php/php-src/branches/PHP_5_2/NEWS   2009-07-27 15:11:46 UTC (rev 286417)
@@ -18,6 +18,7 @@
 - Fixed bug #48913 (Too long error code strings in pdo_odbc driver).
   (naf at altlinux dot ru, Felipe)
 - Fixed bug #48802 (printf() returns incorrect outputted length). (Jani)
+- Fixed bug #48801 (Problem with imagettfbbox). (Takeshi Abe)
 - Fixed bug #48788 (RecursiveDirectoryIterator doesn't descend into symlinked
   directories). (Ilia)
 - Fixed bug #48763 (ZipArchive produces corrupt archive). (dani dot church at
@@ -25,6 +26,8 @@
 - Fixed bug #48762 (IPv6 address filter still rejects valid address). (Felipe)
 - Fixed bug #48733 (CURLOPT_WRITEHEADER|CURLOPT_FILE|CURLOPT_STDERR warns on
   files that have been opened with r+). (Ilia)
+- Fixed bug #48732 (TTF Bounding box wrong for letters below baseline).
+  (Takeshi Abe)
 - Fixed bug #48718 (FILTER_VALIDATE_EMAIL does not allow numbers in domain
   components). (Ilia)
 - Fixed bug #48709 (metaphone and 'wh'). (brettz9 at yahoo dot com, Felipe)

Modified: php/php-src/branches/PHP_5_2/ext/gd/libgd/gdft.c
===
--- php/php-src/branches/PHP_5_2/ext/gd/libgd/gdft.c2009-07-27 15:06:28 UTC 
(rev 286416)
+++ php/php-src/branches/PHP_5_2/ext/gd/libgd/gdft.c2009-07-27 15:11:46 UTC 
(rev 286417)
@@ -785,6 +785,7 @@
int len, i = 0, ch;
int x1 = 0, y1 = 0;
int xb = x, yb = y;
+   int yd = 0;
font_t *font;
fontkey_t fontkey;
char *next;
@@ -919,6 +920,7 @@
}
 #endif

+   i = 0;
while (*next) {
ch = *next;

@@ -934,6 +936,7 @@
}
/* newlines */
if (ch == '\n') {
+   if (!*(++next)) break;
/* 2.0.13: reset penf.x. Christopher J. Grayce */
penf.x = 0;
  penf.y -= (long)(face->size->metrics.height * 
linespace);
@@ -942,9 +945,9 @@
  y1 = (int)(- penf.y * cos_a + 32) / 64;
  xb = x + x1;
  yb = y + y1;
+ yd = 0;
  pen.x = pen.y = 0;
  previous = 0; /* clear kerning flag */
- next++;
  continue;
}

@@ -1058,11 +1061,17 @@
glyph_bbox.xMax += slot->metrics.horiAdvance;
}
if (!i) { /* if first character, init BB corner values 
*/
+   yd = slot->metrics.height - 
slot->metrics.horiBearingY;
bbox.xMin = glyph_bbox.xMin;
bbox.yMin = glyph_bbox.yMin;
bbox.xMax = glyph_bbox.xMax;
bbox.yMax = glyph_bbox.yMax;
} else {
+   FT_Pos desc;
+
+   if ( (desc = (slot->metrics.height - 
slot->metrics.horiBearingY)) > yd) {
+   yd = desc;
+   }
if (bbox.xMin > glyph_bbox.xMin) {
bbox.xMin = glyph_bbox.xMin;
}
@@ -1119,15 +1128,18 @@
normbox.xMax = bbox.xMax - bbox.xMin;
normbox.yMax = bbox.yMax - bbox.yMin;

+   brect[0] = brect[2] = brect[4] = brect[6] = (int)  (yd * sin_a);
+   brect[1] = brect[3] = brect[5] = brect[7] = (int)(- yd * cos_a);
+
/* rotate bounding rectangle */
-   brect[0] = (int) (normbox.xMin * cos_a - normbox.yMin * sin_a);
-   brect[1] = (int) (normbox.xMin * sin_a + normbox.yMin * cos_a);
-   brect[2] = (int) (normbox.xMax * cos_a - normbox.yMin * sin_a);
-   brect[3] = (int) (normbox.xMax * sin_a + normbox.yMin * cos_a);
-   brect[4] = (int) (normbox.xMax * cos_

[PHP-CVS] svn: /php/php-src/branches/PHP_5_3/ext/gd/ libgd/gdft.c tests/bug48555.phpt tests/bug48732.phpt tests/bug48801.phpt

2009-07-27 Thread Takeshi Abe
tabe Mon, 27 Jul 2009 15:06:28 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286416

Log:
MFH: fixed #48732 (TTF Bounding box wrong for letters below baseline) and 
#48801 (Problem with imagettfbbox)

Bugs: http://bugs.php.net/48732 (Assigned) TTF Bounding box wrong for letters 
below baseline
  http://bugs.php.net/48801 (Open) Problem with imagettfbbox
  
Changed paths:
U   php/php-src/branches/PHP_5_3/ext/gd/libgd/gdft.c
U   php/php-src/branches/PHP_5_3/ext/gd/tests/bug48555.phpt
A   php/php-src/branches/PHP_5_3/ext/gd/tests/bug48732.phpt
A   php/php-src/branches/PHP_5_3/ext/gd/tests/bug48801.phpt

Modified: php/php-src/branches/PHP_5_3/ext/gd/libgd/gdft.c
===
--- php/php-src/branches/PHP_5_3/ext/gd/libgd/gdft.c2009-07-27 15:02:15 UTC 
(rev 286415)
+++ php/php-src/branches/PHP_5_3/ext/gd/libgd/gdft.c2009-07-27 15:06:28 UTC 
(rev 286416)
@@ -785,6 +785,7 @@
int len, i = 0, ch;
int x1 = 0, y1 = 0;
int xb = x, yb = y;
+   int yd = 0;
font_t *font;
fontkey_t fontkey;
char *next;
@@ -919,6 +920,7 @@
}
 #endif

+   i = 0;
while (*next) {
ch = *next;

@@ -934,6 +936,7 @@
}
/* newlines */
if (ch == '\n') {
+   if (!*(++next)) break;
/* 2.0.13: reset penf.x. Christopher J. Grayce */
penf.x = 0;
  penf.y -= (long)(face->size->metrics.height * 
linespace);
@@ -942,9 +945,9 @@
  y1 = (int)(- penf.y * cos_a + 32) / 64;
  xb = x + x1;
  yb = y + y1;
+ yd = 0;
  pen.x = pen.y = 0;
  previous = 0; /* clear kerning flag */
- next++;
  continue;
}

@@ -1058,11 +1061,17 @@
glyph_bbox.xMax += slot->metrics.horiAdvance;
}
if (!i) { /* if first character, init BB corner values 
*/
+   yd = slot->metrics.height - 
slot->metrics.horiBearingY;
bbox.xMin = glyph_bbox.xMin;
bbox.yMin = glyph_bbox.yMin;
bbox.xMax = glyph_bbox.xMax;
bbox.yMax = glyph_bbox.yMax;
} else {
+   FT_Pos desc;
+
+   if ( (desc = (slot->metrics.height - 
slot->metrics.horiBearingY)) > yd) {
+   yd = desc;
+   }
if (bbox.xMin > glyph_bbox.xMin) {
bbox.xMin = glyph_bbox.xMin;
}
@@ -1119,15 +1128,18 @@
normbox.xMax = bbox.xMax - bbox.xMin;
normbox.yMax = bbox.yMax - bbox.yMin;

+   brect[0] = brect[2] = brect[4] = brect[6] = (int)  (yd * sin_a);
+   brect[1] = brect[3] = brect[5] = brect[7] = (int)(- yd * cos_a);
+
/* rotate bounding rectangle */
-   brect[0] = (int) (normbox.xMin * cos_a - normbox.yMin * sin_a);
-   brect[1] = (int) (normbox.xMin * sin_a + normbox.yMin * cos_a);
-   brect[2] = (int) (normbox.xMax * cos_a - normbox.yMin * sin_a);
-   brect[3] = (int) (normbox.xMax * sin_a + normbox.yMin * cos_a);
-   brect[4] = (int) (normbox.xMax * cos_a - normbox.yMax * sin_a);
-   brect[5] = (int) (normbox.xMax * sin_a + normbox.yMax * cos_a);
-   brect[6] = (int) (normbox.xMin * cos_a - normbox.yMax * sin_a);
-   brect[7] = (int) (normbox.xMin * sin_a + normbox.yMax * cos_a);
+   brect[0] += (int) (normbox.xMin * cos_a - normbox.yMin * sin_a);
+   brect[1] += (int) (normbox.xMin * sin_a + normbox.yMin * cos_a);
+   brect[2] += (int) (normbox.xMax * cos_a - normbox.yMin * sin_a);
+   brect[3] += (int) (normbox.xMax * sin_a + normbox.yMin * cos_a);
+   brect[4] += (int) (normbox.xMax * cos_a - normbox.yMax * sin_a);
+   brect[5] += (int) (normbox.xMax * sin_a + normbox.yMax * cos_a);
+   brect[6] += (int) (normbox.xMin * cos_a - normbox.yMax * sin_a);
+   brect[7] += (int) (normbox.xMin * sin_a + normbox.yMax * cos_a);

/* scale, round and offset brect */
brect[0] = xb + gdroundupdown(brect[0], d2 > 0);

Modified: php/php-src/branches/PHP_5_3/ext/gd/tests/bug48555.phpt
===
--- php/php-src/branches/PHP_5_3/ext/gd/tests/bug48555.phpt 2009-07-27

[PHP-CVS] svn: /php/php-src/trunk/ext/gd/ libgd/gdft.c tests/bug43073.phpt tests/bug48555.phpt tests/bug48732.phpt tests/bug48801.phpt

2009-07-27 Thread Takeshi Abe
tabe Mon, 27 Jul 2009 15:02:15 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286415

Log:
fixed #48732 (TTF Bounding box wrong for letters below baseline) and #48801 
(Problem with imagettfbbox)

Bugs: http://bugs.php.net/48732 (Assigned) TTF Bounding box wrong for letters 
below baseline
  http://bugs.php.net/48801 (Open) Problem with imagettfbbox
  
Changed paths:
U   php/php-src/trunk/ext/gd/libgd/gdft.c
U   php/php-src/trunk/ext/gd/tests/bug43073.phpt
U   php/php-src/trunk/ext/gd/tests/bug48555.phpt
A   php/php-src/trunk/ext/gd/tests/bug48732.phpt
A   php/php-src/trunk/ext/gd/tests/bug48801.phpt

Modified: php/php-src/trunk/ext/gd/libgd/gdft.c
===
--- php/php-src/trunk/ext/gd/libgd/gdft.c   2009-07-27 14:52:48 UTC (rev 
286414)
+++ php/php-src/trunk/ext/gd/libgd/gdft.c   2009-07-27 15:02:15 UTC (rev 
286415)
@@ -785,6 +785,7 @@
int len, i = 0, ch;
int x1 = 0, y1 = 0;
int xb = x, yb = y;
+   int yd = 0;
font_t *font;
fontkey_t fontkey;
char *next;
@@ -919,6 +920,7 @@
}
 #endif

+   i = 0;
while (*next) {
ch = *next;

@@ -934,6 +936,7 @@
}
/* newlines */
if (ch == '\n') {
+   if (!*(++next)) break;
/* 2.0.13: reset penf.x. Christopher J. Grayce */
penf.x = 0;
  penf.y -= (long)(face->size->metrics.height * 
linespace);
@@ -942,9 +945,9 @@
  y1 = (int)(- penf.y * cos_a + 32) / 64;
  xb = x + x1;
  yb = y + y1;
+ yd = 0;
  pen.x = pen.y = 0;
  previous = 0; /* clear kerning flag */
- next++;
  continue;
}

@@ -1058,11 +1061,17 @@
glyph_bbox.xMax += slot->metrics.horiAdvance;
}
if (!i) { /* if first character, init BB corner values 
*/
+   yd = slot->metrics.height - 
slot->metrics.horiBearingY;
bbox.xMin = glyph_bbox.xMin;
bbox.yMin = glyph_bbox.yMin;
bbox.xMax = glyph_bbox.xMax;
bbox.yMax = glyph_bbox.yMax;
} else {
+   FT_Pos desc;
+
+   if ( (desc = (slot->metrics.height - 
slot->metrics.horiBearingY)) > yd) {
+   yd = desc;
+   }
if (bbox.xMin > glyph_bbox.xMin) {
bbox.xMin = glyph_bbox.xMin;
}
@@ -1119,15 +1128,18 @@
normbox.xMax = bbox.xMax - bbox.xMin;
normbox.yMax = bbox.yMax - bbox.yMin;

+   brect[0] = brect[2] = brect[4] = brect[6] = (int)  (yd * sin_a);
+   brect[1] = brect[3] = brect[5] = brect[7] = (int)(- yd * cos_a);
+
/* rotate bounding rectangle */
-   brect[0] = (int) (normbox.xMin * cos_a - normbox.yMin * sin_a);
-   brect[1] = (int) (normbox.xMin * sin_a + normbox.yMin * cos_a);
-   brect[2] = (int) (normbox.xMax * cos_a - normbox.yMin * sin_a);
-   brect[3] = (int) (normbox.xMax * sin_a + normbox.yMin * cos_a);
-   brect[4] = (int) (normbox.xMax * cos_a - normbox.yMax * sin_a);
-   brect[5] = (int) (normbox.xMax * sin_a + normbox.yMax * cos_a);
-   brect[6] = (int) (normbox.xMin * cos_a - normbox.yMax * sin_a);
-   brect[7] = (int) (normbox.xMin * sin_a + normbox.yMax * cos_a);
+   brect[0] += (int) (normbox.xMin * cos_a - normbox.yMin * sin_a);
+   brect[1] += (int) (normbox.xMin * sin_a + normbox.yMin * cos_a);
+   brect[2] += (int) (normbox.xMax * cos_a - normbox.yMin * sin_a);
+   brect[3] += (int) (normbox.xMax * sin_a + normbox.yMin * cos_a);
+   brect[4] += (int) (normbox.xMax * cos_a - normbox.yMax * sin_a);
+   brect[5] += (int) (normbox.xMax * sin_a + normbox.yMax * cos_a);
+   brect[6] += (int) (normbox.xMin * cos_a - normbox.yMax * sin_a);
+   brect[7] += (int) (normbox.xMin * sin_a + normbox.yMax * cos_a);

/* scale, round and offset brect */
brect[0] = xb + gdroundupdown(brect[0], d2 > 0);

Modified: php/php-src/trunk/ext/gd/tests/bug43073.phpt
===
--- php/php-src/trunk/ext/gd/tests/bug43073.phpt2009-07-27 14:52:48 UTC 
(rev 286414)
+++ php/php-sr

[PHP-CVS] svn: /php/php-src/trunk/ext/standard/ filestat.c

2009-07-27 Thread Felipe Pena
felipe   Mon, 27 Jul 2009 13:21:42 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286403

Log:
- Fix compiler warnings

Changed paths:
U   php/php-src/trunk/ext/standard/filestat.c

Modified: php/php-src/trunk/ext/standard/filestat.c
===
--- php/php-src/trunk/ext/standard/filestat.c   2009-07-27 12:06:27 UTC (rev 
286402)
+++ php/php-src/trunk/ext/standard/filestat.c   2009-07-27 13:21:42 UTC (rev 
286403)
@@ -440,33 +440,35 @@
zval_unicode_to_string(group TSRMLS_CC);
}
 #if defined(ZTS) && defined(HAVE_GETGRNAM_R) && defined(_SC_GETGR_R_SIZE_MAX)
-   struct group gr;
-   struct group *retgrptr;
-   long grbuflen = sysconf(_SC_GETGR_R_SIZE_MAX);
-   char *grbuf;
+   {
+   struct group gr;
+   struct group *retgrptr;
+   long grbuflen = sysconf(_SC_GETGR_R_SIZE_MAX);
+   char *grbuf;

-   if (grbuflen < 1) {
-   RETURN_FALSE;
-   }
+   if (grbuflen < 1) {
+   RETURN_FALSE;
+   }

-   grbuf = emalloc(grbuflen);
-   if (getgrnam_r(Z_STRVAL_P(group), &gr, grbuf, grbuflen, 
&retgrptr) != 0 || retgrptr == NULL) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to 
find gid for %s", Z_STRVAL_P(group));
+   grbuf = emalloc(grbuflen);
+   if (getgrnam_r(Z_STRVAL_P(group), &gr, grbuf, grbuflen, 
&retgrptr) != 0 || retgrptr == NULL) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, 
"Unable to find gid for %s", Z_STRVAL_P(group));
+   efree(grbuf);
+   RETURN_FALSE;
+   }
efree(grbuf);
-   RETURN_FALSE;
+   gid = gr.gr_gid;
}
-   efree(grbuf);
-   gid = gr.gr_gid;
 #else
-{
-   struct group *gr = getgrnam(Z_STRVAL_P(group));
+   {
+   struct group *gr = getgrnam(Z_STRVAL_P(group));

-   if (!gr) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to 
find gid for %s", Z_STRVAL_P(group));
-   RETURN_FALSE;
+   if (!gr) {
+   php_error_docref(NULL TSRMLS_CC, 
E_WARNING, "Unable to find gid for %s", Z_STRVAL_P(group));
+   RETURN_FALSE;
+   }
+   gid = gr->gr_gid;
}
-   gid = gr->gr_gid;
-}
 #endif
} else {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "parameter 2 should 
be string or integer, %s given", zend_zval_type_name(group));
@@ -559,33 +561,35 @@
zval_unicode_to_string(user TSRMLS_CC);
}
 #if defined(ZTS) && defined(_SC_GETPW_R_SIZE_MAX) && defined(HAVE_GETPWNAM_R)
-   struct passwd pw;
-   struct passwd *retpwptr = NULL;
-   long pwbuflen = sysconf(_SC_GETPW_R_SIZE_MAX);
-   char *pwbuf;
+   {
+   struct passwd pw;
+   struct passwd *retpwptr = NULL;
+   long pwbuflen = sysconf(_SC_GETPW_R_SIZE_MAX);
+   char *pwbuf;

-   if (pwbuflen < 1) {
-   RETURN_FALSE;
-   }
+   if (pwbuflen < 1) {
+   RETURN_FALSE;
+   }

-   pwbuf = emalloc(pwbuflen);
-   if (getpwnam_r(Z_STRVAL_P(user), &pw, pwbuf, pwbuflen, 
&retpwptr) != 0 || retpwptr == NULL) {
-   php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to 
find uid for %s", Z_STRVAL_P(user));
+   pwbuf = emalloc(pwbuflen);
+   if (getpwnam_r(Z_STRVAL_P(user), &pw, pwbuf, pwbuflen, 
&retpwptr) != 0 || retpwptr == NULL) {
+   php_error_docref(NULL TSRMLS_CC, E_WARNING, 
"Unable to find uid for %s", Z_STRVAL_P(user));
+   efree(pwbuf);
+   RETURN_FALSE;
+   }
efree(pwbuf);
-   RETURN_FALSE;
+   uid = pw.pw_uid;
}
-   efree(pwbuf);
-   uid = pw.pw_uid;
 #else
-{
-   struct passwd *pw = getpwnam(Z_STRVAL_P(user));
+   {
+   struct passwd *pw = getpwnam(Z_STRVAL_P(user));

-   if (!pw) {
-   php_error_docref(NULL TSRML

[PHP-CVS] svn: /php/php-src/branches/PHP_5_3/ext/standard/ string.c

2009-07-27 Thread Jani Taskinen
jani Mon, 27 Jul 2009 09:23:06 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286391

Log:
- HEAD and PHP_5_2 have it like this, PHP_5_3 should not be different!

Changed paths:
U   php/php-src/branches/PHP_5_3/ext/standard/string.c

Modified: php/php-src/branches/PHP_5_3/ext/standard/string.c
===
--- php/php-src/branches/PHP_5_3/ext/standard/string.c  2009-07-27 08:12:05 UTC 
(rev 286390)
+++ php/php-src/branches/PHP_5_3/ext/standard/string.c  2009-07-27 09:23:06 UTC 
(rev 286391)
@@ -412,12 +412,14 @@
 #endif
 #ifdef DECIMAL_POINT
REGISTER_NL_LANGINFO_CONSTANT(DECIMAL_POINT);
-#elif defined(RADIXCHAR)
+#endif
+#ifdef RADIXCHAR
REGISTER_NL_LANGINFO_CONSTANT(RADIXCHAR);
 #endif
 #ifdef THOUSANDS_SEP
REGISTER_NL_LANGINFO_CONSTANT(THOUSANDS_SEP);
-#elif defined(THOUSEP)
+#endif
+#ifdef THOUSEP
REGISTER_NL_LANGINFO_CONSTANT(THOUSEP);
 #endif
 #ifdef GROUPING

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-CVS] svn: /php/php-src/branches/PHP_5_3/ NEWS ext/standard/string.c

2009-07-27 Thread Kalle Sommer Nielsen
kalleMon, 27 Jul 2009 07:14:40 +

Revision: http://svn.php.net/viewvc?view=revision&revision=286386

Log:
Fixed bug #48872 (string.c: errors: duplicate case values) (Only in PHP_5_3)

Bug: http://bugs.php.net/48872 (Assigned) string.c: errors: duplicate case 
values
  
Changed paths:
U   php/php-src/branches/PHP_5_3/NEWS
U   php/php-src/branches/PHP_5_3/ext/standard/string.c

Modified: php/php-src/branches/PHP_5_3/NEWS
===
--- php/php-src/branches/PHP_5_3/NEWS   2009-07-27 03:43:38 UTC (rev 286385)
+++ php/php-src/branches/PHP_5_3/NEWS   2009-07-27 07:14:40 UTC (rev 286386)
@@ -1,4 +1,4 @@
-PHPNEWS
+PHP
NEWS
 |||
 ?? ??? 2009, PHP 5.3.1
 - Fixed spl_autoload_unregister/spl_autoload_functions wrt. Closures and
@@ -30,6 +30,7 @@
 - Fixed bug #48899 (is_callable returns true even if method does not exist in
   parent class). (Felipe)
 - Fixed bug #48893 (Problems compiling with Curl). (Felipe)
+- Fixed bug #48872 (string.c: errors: duplicate case values). (Kalle)
 - Fixed bug #48854 (array_merge_recursive modifies arrays after first one).
   (Felipe)
 - Fixed bug #48802 (printf() returns incorrect outputted length). (Jani)

Modified: php/php-src/branches/PHP_5_3/ext/standard/string.c
===
--- php/php-src/branches/PHP_5_3/ext/standard/string.c  2009-07-27 03:43:38 UTC 
(rev 286385)
+++ php/php-src/branches/PHP_5_3/ext/standard/string.c  2009-07-27 07:14:40 UTC 
(rev 286386)
@@ -587,14 +587,12 @@
 #endif
 #ifdef DECIMAL_POINT
case DECIMAL_POINT:
-#endif
-#ifdef RADIXCHAR
+#elif defined(RADIXCHAR)
case RADIXCHAR:
 #endif
 #ifdef THOUSANDS_SEP
case THOUSANDS_SEP:
-#endif
-#ifdef THOUSEP
+#elif defined(THOUSEP)
case THOUSEP:
 #endif
 #ifdef GROUPING

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php