Fix void* casting