Re: Someone stomping on our memory

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Wed, 13 Dec 2000 14:38:00 +0100

Stephen R. van den Berg wrote:

> diff -U 2 -b -B -p -r -d --horizon-lines=2 -X /usr/local/etc/xdiff squid-2.2.STA
> BLE3/src/ftp.c squid-B2/src/ftp.c
> --- squid-2.2.STABLE3/src/ftp.c Tue May 11 22:34:36 1999
> +++ squid-B2/src/ftp.c Sun Jun 27 04:52:54 1999
> @@ -1290,5 +1297,6 @@ ftpHandleControlReply(FtpStateData * ftp
> safe_free(ftpState->ctrl.last_reply);
> ftpState->ctrl.last_reply = (*W)->key;
> - safe_free(*W);
> + memFree(*W, MEM_WORDLIST);
> + *W = 0;
> debug(9, 8) ("ftpReadControlReply: state=%d, code=%d\n",

> So it appears that you might have missed another spot still.
> I didn't compare it with the current code yet.

The above fragment in the current code is quite rewritten to abuse
wordlists in a more safe manner which works until wordlists are
restrucured to something more fancy than a single linked list..

/Henrik
Received on Wed Dec 13 2000 - 09:57:39 MST

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