Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: Free stuff properly in zsh/pcre module

On 7 stycznia 2018 at 15:09:39, Mikael Magnusson (mikachu@xxxxxxxxx) wrote:
> Fix a few memleaks of the hints structure, also make sure to free all
> the allocated stuff when the module is unloaded.
> ---
> If you run
> % zmodload zsh/pcre; pcre_compile hey; repeat 1000000; do pcre_study; done
> then zsh mem usage goes up by about 100MB each time.

Maybe Valgrind automatic tests can be integrated for next Zsh release? I've updated the README:


It much helps to track things like the above reported leaks. Today, I was extending a module (an external one) and by logic, the changes couldn't cause any error or leak, but I just ran 7 test-sets, in 5 minutes (excluding the time devoted to updates needed for optimized Zsh build, which was skipping some function calls), and was done.

Sebastian Gniazdowski 
psprint /at/ zdharma.org 

Messages sorted by: Reverse Date, Date, Thread, Author