Fix warning about incompatible pointer types