svn: /php/php-src/branches/PHP_5_3/main/ rfc1867.c
| From: | Arpad Ray | Date: | Mon, 29 Aug 2011 21:11:07 +0000 |
| Subject: | svn: /php/php-src/branches/PHP_5_3/main/ rfc1867.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-66016@lists.php.net to get a copy of this message | ||
arpad Mon, 29 Aug 2011 21:11:07 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=315742
Log:
fix #55510: $_FILES 'name' missing first character after upload
Bug: https://bugs.php.net/55510 (Verified) $_FILES
'name' missing first character after upload.
Changed paths:
U php/php-src/branches/PHP_5_3/main/rfc1867.c
Modified: php/php-src/branches/PHP_5_3/main/rfc1867.c
===================================================================
--- php/php-src/branches/PHP_5_3/main/rfc1867.c 2011-08-29 20:50:33 UTC (rev 315741)
+++ php/php-src/branches/PHP_5_3/main/rfc1867.c 2011-08-29 21:11:07 UTC (rev 315742)
@@ -1210,11 +1210,12 @@
}
#ifdef PHP_WIN32
if (PG(magic_quotes_gpc)) {
- s = s ? s : filename;
- tmp = strrchr(s, '\'');
- s = tmp > s ? tmp : s;
- tmp = strrchr(s, '"');
- s = tmp > s ? tmp : s;
+ if ((tmp = strrchr(s ? s : filename, '\'')) > s) {
+ s = tmp;
+ }
+ if ((tmp = strrchr(s ? s : filename, '"')) > s) {
+ s = tmp;
+ }
}
#endif