summaryrefslogtreecommitdiff
path: root/ext/gettext
diff options
context:
space:
mode:
Diffstat (limited to 'ext/gettext')
-rw-r--r--ext/gettext/gettext.c12
-rw-r--r--ext/gettext/php_gettext.h4
2 files changed, 9 insertions, 7 deletions
diff --git a/ext/gettext/gettext.c b/ext/gettext/gettext.c
index 60c6cb3b8..6dea6d082 100644
--- a/ext/gettext/gettext.c
+++ b/ext/gettext/gettext.c
@@ -2,7 +2,7 @@
+----------------------------------------------------------------------+
| PHP Version 5 |
+----------------------------------------------------------------------+
- | Copyright (c) 1997-2006 The PHP Group |
+ | Copyright (c) 1997-2007 The PHP Group |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: gettext.c,v 1.46.2.2.2.2 2006/09/05 10:36:24 tony2001 Exp $ */
+/* $Id: gettext.c,v 1.46.2.2.2.4 2007/01/16 14:42:38 tony2001 Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -253,9 +253,11 @@ PHP_NAMED_FUNCTION(zif_bindtextdomain)
}
if (Z_STRVAL_PP(dir)[0] != '\0' && strcmp(Z_STRVAL_PP(dir), "0")) {
- VCWD_REALPATH(Z_STRVAL_PP(dir), dir_name);
- } else {
- VCWD_GETCWD(dir_name, MAXPATHLEN);
+ if (!VCWD_REALPATH(Z_STRVAL_PP(dir), dir_name)) {
+ RETURN_FALSE;
+ }
+ } else if (!VCWD_GETCWD(dir_name, MAXPATHLEN)) {
+ RETURN_FALSE;
}
retval = bindtextdomain(Z_STRVAL_PP(domain_name), dir_name);
diff --git a/ext/gettext/php_gettext.h b/ext/gettext/php_gettext.h
index 800127cbf..285db2e03 100644
--- a/ext/gettext/php_gettext.h
+++ b/ext/gettext/php_gettext.h
@@ -2,7 +2,7 @@
+----------------------------------------------------------------------+
| PHP Version 5 |
+----------------------------------------------------------------------+
- | Copyright (c) 1997-2006 The PHP Group |
+ | Copyright (c) 1997-2007 The PHP Group |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_gettext.h,v 1.20.2.1 2006/01/01 12:50:07 sniper Exp $ */
+/* $Id: php_gettext.h,v 1.20.2.1.2.1 2007/01/01 09:36:01 sebastian Exp $ */
#ifndef PHP_GETTEXT_H
#define PHP_GETTEXT_H