--------------------- PatchSet 481 Date: 2002/12/24 21:32:48 Author: rbcollins Branch: esi Tag: (none) Log: remove redundant code Members: src/ESI.cc:1.1.2.85->1.1.2.86 Index: squid3/src/ESI.cc =================================================================== RCS file: /cvsroot/squid-sf//squid3/src/ESI.cc,v retrieving revision 1.1.2.85 retrieving revision 1.1.2.86 diff -u -r1.1.2.85 -r1.1.2.86 --- squid3/src/ESI.cc 24 Dec 2002 21:29:56 -0000 1.1.2.85 +++ squid3/src/ESI.cc 24 Dec 2002 21:32:48 -0000 1.1.2.86 @@ -1,6 +1,6 @@ /* - * $Id: ESI.cc,v 1.1.2.85 2002/12/24 21:29:56 rbcollins Exp $ + * $Id: ESI.cc,v 1.1.2.86 2002/12/24 21:32:48 rbcollins Exp $ * * DEBUG: section 86 ESI processing * AUTHOR: Robert Collins @@ -318,7 +318,6 @@ void start(); bool started; bool sent; - void copyLeadSegment (ESISegment::Pointer &, ESISegment::Pointer); esiInclude(esiInclude const &); }; MemPool *esiInclude::Pool = NULL; @@ -2452,16 +2451,6 @@ } void -esiInclude::copyLeadSegment (ESISegment::Pointer &target, ESISegment::Pointer source) -{ - target = new ESISegment; - xmemcpy (target->buf, source->buf, source->len); - target->len = source->len; - target->next = source->next; - source->next = NULL; -} - -void esiInclude::subRequestDone (esiStreamContext *stream, bool success) { assert (this); @@ -2473,7 +2462,7 @@ /* copy the lead segment */ debug (86,3)("esiIncludeSubRequestDone: Src OK - include PASSED.\n"); assert (!srccontent.getRaw()); - copyLeadSegment (srccontent, stream->localbuffer); + ESISegment::ListTransfer (stream->localbuffer, srccontent); /* we're done! */ flags.finished = 1; } else { @@ -2494,7 +2483,7 @@ debug (86,3)("esiIncludeSubRequestDone: ALT OK.\n"); /* copy the lead segment */ assert (!altcontent.getRaw()); - copyLeadSegment (altcontent, stream->localbuffer); + ESISegment::ListTransfer (stream->localbuffer, altcontent); /* we're done! */ if (!(src || srccontent.getRaw())) { /* src already failed, kick ESI processor */