-const char filters_rcs[] = "$Id: filters.c,v 1.73 2006/12/23 16:01:02 fabiankeil Exp $";
+const char filters_rcs[] = "$Id: filters.c,v 1.74 2006/12/24 17:37:38 fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/filters.c,v $
*
* Revisions :
* $Log: filters.c,v $
+ * Revision 1.74 2006/12/24 17:37:38 fabiankeil
+ * Adjust comment in pcrs_filter_response()
+ * to recent pcrs changes. Hohoho.
+ *
* Revision 1.73 2006/12/23 16:01:02 fabiankeil
* Don't crash if pcre returns an error code
* that pcrs didn't expect. Fixes BR 1621173.
p = strdup("");
for (tl = csp->config->trust_list; (t = *tl) != NULL ; tl++)
{
- sprintf(buf, "<li>%s</li>\n", t->spec);
+ snprintf(buf, sizeof(buf), "<li>%s</li>\n", t->spec);
string_append(&p, buf);
}
err = map(exports, "trusted-referrers", 1, p, 0);
p = strdup("");
for (l = csp->config->trust_info->first; l ; l = l->next)
{
- sprintf(buf, "<li> <a href=\"%s\">%s</a><br>\n",l->str, l->str);
+ snprintf(buf, sizeof(buf), "<li> <a href=\"%s\">%s</a><br>\n", l->str, l->str);
string_append(&p, buf);
}
err = map(exports, "trust-info", 1, p, 0);
{
return(NULL);
}
- size = csp->iob->eod - csp->iob->cur;
+ size = (size_t)(csp->iob->eod - csp->iob->cur);
/*
* Need to check the set of re_filterfiles...
{
struct binbuffer *in, *out;
char *p;
- size_t size = csp->iob->eod - csp->iob->cur;
+ size_t size;
+
+ size = (size_t)(csp->iob->eod - csp->iob->cur);
/*
* If the body has a "chunked" transfer-encoding,
*********************************************************************/
char *jpeg_inspect_response(struct client_state *csp)
{
- struct binbuffer *in = NULL, *out = NULL;
+ struct binbuffer *in = NULL;
+ struct binbuffer *out = NULL;
char *p = NULL;
- size_t size = csp->iob->eod - csp->iob->cur;
+ size_t size;
+
+ size = (size_t)(csp->iob->eod - csp->iob->cur);
/*
* If the body has a "chunked" transfer-encoding,
* went wrong
*
*********************************************************************/
-int remove_chunked_transfer_coding(char *buffer, const size_t size)
+size_t remove_chunked_transfer_coding(char *buffer, const size_t size)
{
size_t newsize = 0;
unsigned int chunksize = 0;