rasmus Wed Oct 22 20:13:06 2008 UTC
Modified files:
/pecl/apc apc_main.c apc_signal.c
Log:
- Fix segfault on an empty opened path (cli version)
- APC_HAVE_SIGACTION isn't defined anywhere. Switch to HAVE_SIGACTION
and make sure we include the file that defines it before trying to check
it
http://cvs.php.net/viewvc.cgi/pecl/apc/apc_main.c?r1=3.127&r2=3.128&diff_format=u
Index: pecl/apc/apc_main.c
diff -u pecl/apc/apc_main.c:3.127 pecl/apc/apc_main.c:3.128
--- pecl/apc/apc_main.c:3.127 Mon Aug 18 13:49:59 2008
+++ pecl/apc/apc_main.c Wed Oct 22 20:13:06 2008
@@ -28,7 +28,7 @@
*/
-/* $Id: apc_main.c,v 3.127 2008/08/18 13:49:59 gopalv Exp $ */
+/* $Id: apc_main.c,v 3.128 2008/10/22 20:13:06 rasmus Exp $ */
#include "apc_php.h"
#include "apc_main.h"
@@ -356,7 +356,7 @@
}
/* check our regular expression filters */
- if (APCG(filters) && apc_compiled_filters) {
+ if (APCG(filters) && apc_compiled_filters && h->opened_path) {
int ret = apc_regex_match_array(apc_compiled_filters, h->opened_path);
if(ret == APC_NEGATIVE_MATCH || (ret != APC_POSITIVE_MATCH && !APCG(cache_by_default))) {
/* never cache, never find */
http://cvs.php.net/viewvc.cgi/pecl/apc/apc_signal.c?r1=1.7&r2=1.8&diff_format=u
Index: pecl/apc/apc_signal.c
diff -u pecl/apc/apc_signal.c:1.7 pecl/apc/apc_signal.c:1.8
--- pecl/apc/apc_signal.c:1.7 Mon Oct 20 17:12:15 2008
+++ pecl/apc/apc_signal.c Wed Oct 22 20:13:06 2008
@@ -24,7 +24,7 @@
All other licensing and usage conditions are those of the PHP Group.
*/
- /* $Id: apc_signal.c,v 1.7 2008/10/20 17:12:15 shire Exp $ */
+ /* $Id: apc_signal.c,v 1.8 2008/10/22 20:13:06 rasmus Exp $ */
/* Allows apc to install signal handlers and maintain signalling
to already registered handlers. Registers all signals that
@@ -34,8 +34,9 @@
be called in request init (RINIT)
*/
-#if APC_HAVE_SIGACTION
+#include "config.h"
+#if HAVE_SIGACTION
#include <signal.h>
#include "apc_globals.h"
#include "apc_sma.h"
@@ -184,7 +185,7 @@
}
}
-#endif /* APC_HAVE_SIGACTION */
+#endif /* HAVE_SIGACTION */
/*
* Local variables:
|