* evade double calls to output_headers
authorWilfried Göesgens <willi@citadel.org>
Sat, 25 Apr 2009 22:21:32 +0000 (22:21 +0000)
committerWilfried Göesgens <willi@citadel.org>
Sat, 25 Apr 2009 22:21:32 +0000 (22:21 +0000)
webcit/downloads.c
webcit/messages.c
webcit/webcit.c

index 82079a39d23a963c9de1bce52e2c8714f5566ff2..2de8a4d130a7a51ed86a1708c60439df8218ff2a 100644 (file)
@@ -258,7 +258,6 @@ void download_file(void)
                if (!force_download) {
                        StrBufExtract_token(ContentType, Buf, 3, '|');
                }
-               output_headers(0, 0, 0, 0, 0, 0);
                read_server_binary(WCC->WBuf, bytes, Buf);
                serv_puts("CLOS");
                StrBuf_ServGetlnBuffered(Buf);
index f10f3bbdf3540f77b7207ab686dbce29ac663cf9..6c8a97eb7ca390a5309a4c6ffd6ea4ee0f97bd48 100644 (file)
@@ -1515,7 +1515,6 @@ void postpart(StrBuf *partnum, StrBuf *filename, int force_download)
                else {
                        content_type = NewStrBufDup(part->ContentType);
                }
-               output_headers(0, 0, 0, 0, 0, 0);
                StrBufAppendBuf(WC->WBuf, part->Data, 0);
                http_transmit_thing(ChrPtr(content_type), 0);
        } else {
@@ -1569,7 +1568,6 @@ void mimepart(int force_download)
                                CT = GuessMimeType(SKEY(WCC->WBuf));
                        }
                }
-               output_headers(0, 0, 0, 0, 0, 0);
                http_transmit_thing(CT, 0);
        } else {
                StrBufCutLeft(Buf, 4);
index b2060a16b00368a4decb63f7e172a58f59d3d7db..d7beab0c3bd9ca85d17ca3082f3fe0b96740f667 100644 (file)
@@ -378,7 +378,6 @@ void url_do_template(void) {
        const StrBuf *MimeType;
        const StrBuf *Tmpl = sbstr("template");
        begin_burst();
-       output_headers(0, 0, 0, 0, 1, 0);
        MimeType = DoTemplate(SKEY(Tmpl), NULL, &NoCtx);
        http_transmit_thing(ChrPtr(MimeType), 0);
 }