For Programmers: Free Programming Magazines  


Home > Archive > PHP Zend Engine > August 2005 > cvs: ZendEngine2(PHP_5_1) / zend_builtin_functions.c









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author cvs: ZendEngine2(PHP_5_1) / zend_builtin_functions.c
Stanislav Malyshev

2005-08-22, 6:57 pm

stas Mon Aug 22 09:26:34 2005 EDT

Modified files: (Branch: PHP_5_1)
/ZendEngine2 zend_builtin_functions.c
Log:
fix crash if throw attempted outside of executable code


http://cvs.php.net/diff.php/ZendEng...=1.277.2.2&ty=u
Index: ZendEngine2/zend_builtin_functions.c
diff -u ZendEngine2/zend_builtin_functions.c:1.277.2.1 ZendEngine2/zend_builtin_functions.c:1.277.2.2
--- ZendEngine2/zend_builtin_functions.c:1.277.2.1 Thu Aug 18 11:13:45 2005
+++ ZendEngine2/zend_builtin_functions.c Mon Aug 22 09:26:33 2005
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/

-/* $Id: zend_builtin_functions.c,v 1.277.2.1 2005/08/18 15:13:45 tony2001 Exp $ */
+/* $Id: zend_builtin_functions.c,v 1.277.2.2 2005/08/22 13:26:33 stas Exp $ */

#include "zend.h"
#include "zend_API.h"
@@ -1847,7 +1847,7 @@
ptr = EG(current_execute_data);

/* skip "new Exception()" */
- if ((skip_last == 0) && ptr->opline && (ptr->opline->opcode == ZEND_NEW)) {
+ if (ptr && (skip_last == 0) && ptr->opline && (ptr->opline->opcode == ZEND_NEW)) {
ptr = ptr->prev_execute_data;
}

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com