rrichards               Mon Jan 26 19:10:54 2009 UTC

  Modified files:              (Branch: PHP_5_3)
    /php-src/ext/dom    document.c 
  Log:
  MFH: fix bug #47220 (segfault in dom_document_parser in recovery mode)
  
http://cvs.php.net/viewvc.cgi/php-src/ext/dom/document.c?r1=1.68.2.3.2.5.2.13&r2=1.68.2.3.2.5.2.14&diff_format=u
Index: php-src/ext/dom/document.c
diff -u php-src/ext/dom/document.c:1.68.2.3.2.5.2.13 
php-src/ext/dom/document.c:1.68.2.3.2.5.2.14
--- php-src/ext/dom/document.c:1.68.2.3.2.5.2.13        Wed Dec 31 11:15:36 2008
+++ php-src/ext/dom/document.c  Mon Jan 26 19:10:53 2009
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: document.c,v 1.68.2.3.2.5.2.13 2008/12/31 11:15:36 sebastian Exp $ */
+/* $Id: document.c,v 1.68.2.3.2.5.2.14 2009/01/26 19:10:53 rrichards Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -1625,7 +1625,7 @@
                        EG(error_reporting) = old_error_reporting;
                }
                /* If loading from memory, set the base reference uri for the 
document */
-               if (ret->URL == NULL && ctxt->directory != NULL) {
+               if (ret && ret->URL == NULL && ctxt->directory != NULL) {
                        ret->URL = xmlStrdup(ctxt->directory);
                }
        } else {



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to