-const char jcc_rcs[] = "$Id: jcc.c,v 1.130 2007/04/19 13:47:34 fabiankeil Exp $";
+const char jcc_rcs[] = "$Id: jcc.c,v 1.131 2007/04/22 13:24:50 fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/jcc.c,v $
*
* Revisions :
* $Log: jcc.c,v $
+ * Revision 1.131 2007/04/22 13:24:50 fabiankeil
+ * Make HTTP snippets static (again). Add a Content-Type for those
+ * with content so the browser doesn't guess it based on the URL.
+ *
* Revision 1.130 2007/04/19 13:47:34 fabiankeil
* Move crunching and request line rebuilding out of chat().
*
log_error(LOG_LEVEL_FATAL, "Out of memory parsing server header");
}
+ /*
+ * Shouldn't happen because this was the second sed run
+ * and tags are only created for the first one.
+ */
+ assert(!crunch_response_triggered(csp));
+
if (write_socket(csp->cfd, hdr, strlen(hdr))
|| write_socket(csp->cfd, p != NULL ? p : csp->iob->cur, csp->content_length))
{
return;
}
+ if (crunch_response_triggered(csp))
+ {
+ /*
+ * One of the tags created by a server-header
+ * tagger triggered a crunch. We already
+ * delivered the crunch response to the client
+ * and are done here after cleaning up.
+ */
+ freez(hdr);
+ return;
+ }
+
hdrlen = strlen(hdr);
if (write_socket(csp->cfd, hdr, hdrlen)
log_error(LOG_LEVEL_FATAL, "Out of memory parsing server header");
}
+ if (crunch_response_triggered(csp))
+ {
+ /*
+ * One of the tags created by a server-header
+ * tagger triggered a crunch. We already
+ * delivered the crunch response to the client
+ * and are done here after cleaning up.
+ */
+ freez(hdr);
+ return;
+ }
#ifdef FEATURE_KILL_POPUPS
/* Start blocking popups if appropriate. */