[Mongrel] Mongrel and memory usage
wyhaines at gmail.com
Tue Nov 6 09:54:56 EST 2007
On 11/6/07, Bob Hutchison <hutch at recursive.ca> wrote:
> It isn't fixed in the ruby that ships with Leopard:
> 1.8.6 (2007-06-07 patchlevel 36) [universal-darwin9.0]
Ugh. IIRC I checked it with the patch release after 36, and it was fixed there.
> This hack will fix things.
> class Array
> alias :naughty_shift :shift
> def shift
> result = self.first
> self = nil # This is the 'magic'
Note that this just _mostly_ fixes things. You still end up with
array elements in memory carrying around Qnils, but most of the time
that's good enough.
More information about the Mongrel-users