summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Joye <pajoye@php.net>2007-07-30 21:42:36 +0000
committerPierre Joye <pajoye@php.net>2007-07-30 21:42:36 +0000
commit6ed7c8f3aa11fde67e8628afdf18bf7133822db5 (patch)
treee5b6defcd708a9436f16023d0700fe8d78500294
parentb96718ba202a88743c5e5d9c2471affaa70708fb (diff)
downloadphp-git-6ed7c8f3aa11fde67e8628afdf18bf7133822db5.tar.gz
- fix gd bug #102, < 0 means that no load are loaded, return false
- add error code in the warning
-rw-r--r--ext/gd/gd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/gd/gd.c b/ext/gd/gd.c
index 834e2b7501..f880b69905 100644
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
@@ -4363,7 +4363,8 @@ PHP_FUNCTION(imagepsloadfont)
f_ind = T1_AddFont(Z_STRVAL_PP(file));
if (f_ind < 0) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "T1Lib Error: %s", T1_StrError(f_ind));
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "T1Lib Error (%i): %s", f_ind, T1_StrError(f_ind));
+ RETURN_FALSE;
}
if (T1_LoadFont(f_ind)) {