rm extra malloc call