store entry question

From: Matt Tuzzolo <mtuzzolo@dont-contact.us>
Date: Wed, 16 Apr 2003 09:39:31 -0400 (EDT)

Hey,
        I'm trying to reset a store entry and then fill it with my own
data. My code basically looks like this:

<------(entry contains "</html>")
storeMemObjectDump(entry->mem_obj);
storeEntryReset(entry);
storeAppend(entry, "blah", 4);
storeMemObjectDump(entry->mem_obj);
<------(entry now contains "</html>blah" should be "blah")

But storeMemObjectDump prints the same data each time and the client
still recieves the pre-existing content. Is storeEntryReset
not actually freeing the data_hdr? I can only find one other call to
storeEntryReset so I don't have much to go on.

I was previously just appending my data after the read, but this only
works for dynamically generated sites (where the CL is unknown), so that's
no good (although some browsers will actually just ignore the
content-length and read from the socket indefinitely). I need to
somehow get rid of what's already in this entry and recreate it with my
own content so this is compatible with browsers that pay attention to the
content-length.

Any suggestions?

-Matt

---------------------------
Matt Tuzzolo
Merrimack Education Center
978.262.4000
---------------------------
Received on Wed Apr 16 2003 - 07:39:15 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:19:41 MST