]> git.ipfire.org Git - thirdparty/squid.git/commit
Fixed free() errors in AuthUser::~AuthUser()
authorwessels <>
Wed, 9 May 2007 14:26:57 +0000 (14:26 +0000)
committerwessels <>
Wed, 9 May 2007 14:26:57 +0000 (14:26 +0000)
commit3f5f1a0170e2be74f12247a1c65f495cf5235102
treec6321d40f1abb58136b576ac74907afab905f8a3
parent3ad9fcbce7d0a698084df908d403a3e0f3864811
Fixed free() errors in AuthUser::~AuthUser()

AuthUser::~AuthUser() was freeing memory in the middle of an allocated
buffer.  I think AuthUser needs a strdup'd copy of the username,
rather than keeping a pointer to the buffer read from the helper.

Also I found 'xfree((char *)username());' really odd.  This username()
method does not return a reference so it shouldn't be used as LHS
in the macro.
src/AuthUser.cc
src/AuthUser.cci
src/AuthUser.h