wez Tue Dec 2 19:56:15 2003 EDT Modified files: /php-src/win32/build confutils.js Log: Avoid death when wrapping null/undefined values Index: php-src/win32/build/confutils.js diff -u php-src/win32/build/confutils.js:1.2 php-src/win32/build/confutils.js:1.3 --- php-src/win32/build/confutils.js:1.2 Tue Dec 2 19:15:10 2003 +++ php-src/win32/build/confutils.js Tue Dec 2 19:56:14 2003 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -// $Id: confutils.js,v 1.2 2003/12/03 00:15:10 wez Exp $ +// $Id: confutils.js,v 1.3 2003/12/03 00:56:14 wez Exp $ var STDOUT = WScript.StdOut; var STDERR = WScript.StdErr; @@ -88,6 +88,10 @@ function word_wrap_and_indent(indent, text, line_suffix, indent_char) { + if (text == null) { + return ""; + } + var words = text.split(new RegExp("\\s+", "g")); var i = 0; var ret_text = "";
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php