bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: String replacements leak small amounts of memory each time


From: Øyvind Hvidsten
Subject: Re: String replacements leak small amounts of memory each time
Date: Mon, 14 Jun 2010 23:25:42 +0200
User-agent: Cathedral Secure Mail v0.8

It would seem Debian Squeeze uses that option as default.
Without it, I get a whole ton of warnings, and errors about "free", "malloc" and "realloc" being defines multiple times.

Have you tried to reproduce the problem outside of Valgrind? Just running the examples and looking at the memory usage? I've tried on two different machines now, with bash 4.1.5 and 3.2.25, and it happens on both, though it does seem to happen a lot faster on 4.1.5. Other people in #bash have reproduced it too.

By the way it seems one of my slashes were removed at some point. The testcases need to be run in the / directory, or the command has to be:
while read line; do test=${line#\ }; done < <(ls -lR /)
..in order to generate enough input to reproduce the issue.

On 14/06/10 04:52, Chet Ramey wrote:
On 6/13/10 5:33 PM, Øyvind Hvidsten wrote:
It could be logical leaks, or whatever is the correct english term for
them. Memory that's used, and kept track of, but not used again, and not
freed until the program shuts down. The memory usage is constantly
increasing. I have a process using 3 gigs now, and it just runs one of
those testcases (on a lot more data).

You could try using the system malloc instead of the one that comes with
bash.  Configure --without-bash-malloc and see if that changes the
allocation behavior.

Chet




reply via email to

[Prev in Thread] Current Thread [Next in Thread]