Fix leaking global variable
Merge pull request #91 from osmestad/master

Fix leaking global variable