From: wessels <> Date: Thu, 12 Jan 2006 03:59:58 +0000 (+0000) Subject: Changed debugging locations for MemObject constructor and destructor X-Git-Tag: SQUID_3_0_PRE4~373 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=510fc064bbada956b95f3d659298dc1a7880f3cd;p=thirdparty%2Fsquid.git Changed debugging locations for MemObject constructor and destructor so they print at the start of the function. In the destructor there is no need to check that _reply is set because nobody else deletes it. --- diff --git a/src/MemObject.cc b/src/MemObject.cc index 6900f13b5b..d8438fc9ad 100644 --- a/src/MemObject.cc +++ b/src/MemObject.cc @@ -1,6 +1,6 @@ /* - * $Id: MemObject.cc,v 1.18 2005/11/05 00:08:32 wessels Exp $ + * $Id: MemObject.cc,v 1.19 2006/01/11 20:59:58 wessels Exp $ * * DEBUG: section 19 Store Memory Primitives * AUTHOR: Robert Collins @@ -75,6 +75,7 @@ MemObject::inUseCount() MemObject::MemObject(char const *aUrl, char const *aLog_url) { + debugs(20, 0, HERE << "new MemObject " << this); _reply = new HttpReply; url = xstrdup(aUrl); #if URL_CHECKSUM_DEBUG @@ -85,13 +86,12 @@ MemObject::MemObject(char const *aUrl, char const *aLog_url) log_url = xstrdup(aLog_url); object_sz = -1; /* XXX account log_url */ - debug(20, 3) ("MemObject::MemObject: initialized %p\n", this); } MemObject::~MemObject() { + debugs(20, 0, HERE << "del MemObject " << this); const Ctx ctx = ctx_enter(url); - debug(20, 3) ("destroy_MemObject: destroying %p\n", this); #if URL_CHECKSUM_DEBUG assert(chksum == url_checksum(url)); @@ -111,8 +111,7 @@ MemObject::~MemObject() #endif - if (_reply) - delete _reply; + delete _reply; requestUnlink(request);