- fixed memory leak (thanks to bagobor)