Fix/memory leak 2

https://github.com/globaleaks/GlobaLeaks/issues/611

ready for integration

@vecna can you retest it that @hellais can't?

so we can schedule a package relase for this night.