code clean-up for malloc(); move on to free()