releaseMemStorage no longer causes a segfault.

I was getting a segfault when `releaseMemStorage` was called. Simply wrapping it like this, using the previously commented out code, seems to work. Is there something that I'm missing here?