Gravitational redshift and the vacuum index of refraction