summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph M. Becker <cmb@php.net>2016-07-19 00:53:46 +0200
committerChristoph M. Becker <cmb@php.net>2016-07-19 00:55:13 +0200
commit2f81707425694a9c970807c48ff714e52f8769e4 (patch)
treedd17b39b73179b3da6a550ef645a95ff5de351c2
parentd91e2e47d4cd68b2d9978181a36d5c304f61eb51 (diff)
parentd565d4bc1cab2d695863a51eb6f998405b76c147 (diff)
downloadphp-git-2f81707425694a9c970807c48ff714e52f8769e4.tar.gz
Merge branch 'PHP-7.0'
-rw-r--r--NEWS1
-rw-r--r--ext/gd/gd.c17
2 files changed, 17 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 77583677f4..e1b75738aa 100644
--- a/NEWS
+++ b/NEWS
@@ -47,6 +47,7 @@ PHP NEWS
- GD:
. Fixed bug #72596 (imagetypes function won't advertise WEBP support). (cmb)
. Fixed bug #72604 (imagearc() ignores thickness for full arcs). (cmb)
+ . Fixed bug #70315 (500 Server Error but page is fully rendered). (cmb)
- Intl:
. Partially fixed #72506 (idn_to_ascii for UTS #46 incorrect for long domain
diff --git a/ext/gd/gd.c b/ext/gd/gd.c
index a8ed6309df..c0319b2c93 100644
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
@@ -63,6 +63,9 @@
static int le_gd, le_gd_font;
#include <gd.h>
+#ifndef HAVE_GD_BUNDLED
+# include <gd_errors.h>
+#endif
#include <gdfontt.h> /* 1 Tiny font */
#include <gdfonts.h> /* 2 Small font */
#include <gdfontmb.h> /* 3 Medium bold font */
@@ -1021,7 +1024,19 @@ static void php_free_gd_font(zend_resource *rsrc)
void php_gd_error_method(int type, const char *format, va_list args)
{
- php_verror(NULL, "", type, format, args);
+ switch (type) {
+ case GD_DEBUG:
+ case GD_INFO:
+ case GD_NOTICE:
+ type = E_NOTICE;
+ break;
+ case GD_WARNING:
+ type = E_WARNING;
+ break;
+ default:
+ type = E_ERROR;
+ }
+ php_verror(NULL, "", type, format, args TSRMLS_CC);
}
/* }}} */
#endif