summaryrefslogtreecommitdiff
path: root/sapi/caudium
diff options
context:
space:
mode:
authorDavid Hedbor <neotron@php.net>2000-12-07 19:01:13 +0000
committerDavid Hedbor <neotron@php.net>2000-12-07 19:01:13 +0000
commit9147a81a19739464cbcc008a08d143d8aa1848c4 (patch)
tree1dd75b8436d162b5ccb104a52c37174e9da00ca2 /sapi/caudium
parent6c0ed47a6c4f9733cd2f649b9ef908ec60b205c5 (diff)
downloadphp-git-9147a81a19739464cbcc008a08d143d8aa1848c4.tar.gz
Fix for Pike 7.1 (error -> Pike_error). Caudium bug #12486.
Diffstat (limited to 'sapi/caudium')
-rw-r--r--sapi/caudium/caudium.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/sapi/caudium/caudium.c b/sapi/caudium/caudium.c
index 1a869781e8..747179f200 100644
--- a/sapi/caudium/caudium.c
+++ b/sapi/caudium/caudium.c
@@ -46,7 +46,6 @@
#include <pike_types.h>
#include <interpret.h>
#include <module_support.h>
-#include <error.h>
#include <array.h>
#include <backend.h>
#include <stralloc.h>
@@ -57,6 +56,15 @@
#include <operators.h>
#include <version.h>
+#if (PIKE_MAJOR_VERSION == 7 && PIKE_MINOR_VERSION == 1 && PIKE_BUILD_VERSION >= 12) || PIKE_MAJOR_VERSION > 7 || (PIKE_MAJOR_VERSION == 7 && PIKE_MINOR_VERSION > 1)
+# include "pike_error.h"
+#else
+# include "error.h"
+# ifndef Pike_error
+# define Pike_error error
+# endif
+#endif
+
#ifndef ZTS
/* Need thread safety */
#error You need to compile PHP with threads.
@@ -713,15 +721,15 @@ void f_php_caudium_request_handler(INT32 args)
php_caudium_request *_request;
THIS = malloc(sizeof(php_caudium_request));
if(THIS == NULL)
- error("Out of memory.");
+ Pike_error("Out of memory.");
// if(current_thread == th_self())
- // error("PHP4.Interpreter->run: Tried to run a PHP-script from a PHP "
+ // Pike_error("PHP4.Interpreter->run: Tried to run a PHP-script from a PHP "
// "callback!");
get_all_args("PHP4.Interpreter->run", args, "%S%m%O%*", &script,
&request_data, &my_fd_obj, &done_callback);
if(done_callback->type != PIKE_T_FUNCTION)
- error("PHP4.Interpreter->run: Bad argument 4, expected function.\n");
+ Pike_error("PHP4.Interpreter->run: Bad argument 4, expected function.\n");
add_ref(request_data);
add_ref(my_fd_obj);
add_ref(script);