- From: Markku Savela <msa@msa.tte.vtt.fi>
- Date: Wed, 7 Aug 1996 17:05:46 +0300 (EET DST)
- To: www-lib-bugs@w3.org
- Cc: msa@msa.tte.vtt.fi, frystyk@w3.org
HTMIME_putblock bugs have already been reported earlier by Joe Pallas. I am just reporting, because the same bug was the reason why my programs didn't work with "Location:" headers (SiteTrack fails to put content-type headers on redirect reply and WWWLIB crashes). Another bug is the point that, the terminating '\n' character from the headers get inserted into the content of the output. This doesn't hurt HTML, but messes up image files badly. After making the following hacks, I got it working, but I think these are not really proper way to fix it. *** HTMIME.c.ORIG Fri Jun 7 07:42:26 1996 --- HTMIME.c Wed Aug 7 16:45:17 1996 *************** *** 206,211 **** --- 206,212 ---- if (me->EOLstate == EOL_END) { /* EOL_END */ if (status == HT_OK) status = pumpData(me); + --l; /* For header terminating NL? --msa */ HTNet_setBytesRead(me->net, l); } else { /* EOL_LINE */ HTChunk_clear(me->token); *************** *** 248,253 **** --- 249,256 ---- ** Put the rest down the stream without touching the data but make sure ** that we get the correct content length of data */ + if (!me->target) /* A quick hack solution for missing content-type! --msa */ + return HT_OK; if ((status = (*me->target->isa->put_block)(me->target, b, l)) != HT_OK) return status; /* Check if CL at all - thanks to jwei@hal.com (John Wei) */ -- Markku Savela (msa@hemuli.tte.vtt.fi), Technical Research Centre of Finland Multimedia Systems, P.O.Box 1203,FIN-02044 VTT,http://www.vtt.fi/tte/staff/msa/
Received on Wednesday, 7 August 1996 17:00:09 UTC