[json] Fix all teh leaks