fixed memory leak on input parameters

@joeferner I had stressed read operations before. Now I'm stressing writes and found this memory leak (was easy to fix). With this fix I get flat memory usage with processes that write for more than an hour.

Might be worth publishing a new version to NPM as the recent PRs fixed memory leaks.