correcting void * dereferencing warning