Cast pointers to avoid compiler error.