c function returns two pointers with different types