PATCH: Retaining truly _original_ headers

Hello everybody, 

The attached patch corrects what I would call a bug (It cannot be a
feature). It regards the handling of the stored original headers in
HTAnchor and HTResponse. Both object types provide for specialized
routines to access the values of various header lines. However, those
routines destroy the header values by inserting a lot of 0-bytes. Thus,
when trying to access the original headers (To store them away, to return
them for a TRACE request, whatever), they are already destroyed, because
some of those specialized routines get called internally by libwww.


The attached patch corrects this by introducting and using a new parsing
function (actually just a variant of the original function).


If any code that uses libwww is broken by this change, I would call the
user code buggy, because it may use incomplete header information at
present.


There are a lot of uses of the HTNextField function in other parts of the
library. I did not check if there is a similar problem lurking in those
parts of the library as well. If somebody could check thise cases, please
do so and tell me your results.

The patch should apply cleanly within Library/src

peter

Received on Tuesday, 5 September 2000 10:23:52 UTC