Limit the proliferation of Grids to avoid more leaks
Merge pull request #23 from sotty/master

Avoid thread and memory leaks