-const char cgi_rcs[] = "$Id: cgi.c,v 1.70.2.6 2003/03/12 01:26:25 david__schmidt Exp $";
+const char cgi_rcs[] = "$Id: cgi.c,v 1.70.2.9 2003/05/08 15:11:31 oes Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/Attic/cgi.c,v $
*
* Revisions :
* $Log: cgi.c,v $
+ * Revision 1.70.2.9 2003/05/08 15:11:31 oes
+ * Nit
+ *
+ * Revision 1.70.2.8 2003/04/29 13:33:51 oes
+ * Killed a compiler warning on OSX
+ *
+ * Revision 1.70.2.7 2003/04/03 13:50:58 oes
+ * - Don't call cgi_error_disabled ifndef FEATURE_CGI_EDIT_ACTIONS
+ * (fixes bug #710056)
+ * - Show toggle info only if we have it
+ *
* Revision 1.70.2.6 2003/03/12 01:26:25 david__schmidt
* Move declaration of struct tm dummy outside of a control block so it is
* accessible later on during snprintf in get_http_time.
/*
- * Bulit-in images for ad replacement
+ * Built-in images for ad replacement
*
* Hint: You can encode your own images like this:
* cat your-image | perl -e 'while (read STDIN, $c, 1) { printf("\\%.3o", unpack("C", $c)); }'
if ((d->name == NULL) || (strcmp(path_copy, d->name) == 0))
{
/*
- * If the called CGI is either harmless, or not referred
- * from an untrusted source, start it.
+ * If the called CGI is either harmless, or referred
+ * from a trusted source, start it.
*/
if (d->harmless
- || (NULL == (referrer = grep_cgi_referrer(csp)))
- || (0 == strncmp(referrer, "http://config.privoxy.org/", 26))
+ || ((NULL != (referrer = grep_cgi_referrer(csp)))
+ && (0 == strncmp(referrer, "http://config.privoxy.org/", 26)))
)
{
err = (d->handler)(csp, rsp, param_list);
struct tm *t;
time_t current_time;
-#ifdef HAVE_GMTIME_R
+#if defined(HAVE_GMTIME_R) && !defined(OSX_DARWIN)
/*
* Declare dummy up here (instead of inside get/set gmt block) so it
* doesn't go out of scope before it's potentially used in snprintf later.