X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=http_exception_object.c;h=8e1ffeedeed79a18c170484efcd688a6b5f4882f;hp=3fc2bc90eb01e3d891edf166f01b222891ba99bc;hb=32e91737086db53bb1fd9ed9f79d693c43ec459f;hpb=e83a7438dc70ed96630887246a1d3aefcf155b1c diff --git a/http_exception_object.c b/http_exception_object.c index 3fc2bc9..8e1ffee 100644 --- a/http_exception_object.c +++ b/http_exception_object.c @@ -6,7 +6,7 @@ | modification, are permitted provided that the conditions mentioned | | in the accompanying LICENSE file are met. | +--------------------------------------------------------------------+ - | Copyright (c) 2004-2005, Michael Wallner | + | Copyright (c) 2004-2006, Michael Wallner | +--------------------------------------------------------------------+ */ @@ -16,19 +16,14 @@ #ifdef HAVE_CONFIG_H # include "config.h" #endif -#include "php.h" -#ifdef ZEND_ENGINE_2 +#include "php_http.h" -#include "zend_exceptions.h" +#ifdef ZEND_ENGINE_2 -#include "php_http.h" -#include "php_http_std_defs.h" #include "php_http_exception_object.h" -#define HTTP_EX_DEF_CE http_exception_object_ce zend_class_entry *http_exception_object_ce; -#define HTTP_EX_CE(name) http_ ##name## _exception_object_ce zend_class_entry *HTTP_EX_CE(runtime); zend_class_entry *HTTP_EX_CE(header); zend_class_entry *HTTP_EX_CE(malformed_headers); @@ -57,6 +52,8 @@ PHP_MINIT_FUNCTION(http_exception_object) HTTP_REGISTER_EXCEPTION(HttpSocketException, HTTP_EX_CE(socket), HTTP_EX_DEF_CE); HTTP_REGISTER_EXCEPTION(HttpResponseException, HTTP_EX_CE(response), HTTP_EX_DEF_CE); HTTP_REGISTER_EXCEPTION(HttpUrlException, HTTP_EX_CE(url), HTTP_EX_DEF_CE); + + zend_declare_property_null(HTTP_EX_CE(request_pool), "exceptionStack", lenof("exceptionStack"), ZEND_ACC_PUBLIC TSRMLS_CC); HTTP_LONG_CONSTANT("HTTP_E_RUNTIME", HTTP_E_RUNTIME); HTTP_LONG_CONSTANT("HTTP_E_INVALID_PARAM", HTTP_E_INVALID_PARAM);