Explictly free some pointers and/or reuse existing pointers instead of creating new ones.