X-ray photon correlation is used to probe the slow dynamics of the glass-former B2O3 across the glass transition. In the undercooled liquid phase the decay times of the measured correlation functions are consistent with visible light scattering results and independent of the incoming flux; in the glass they are instead temperature independent and show a definite dependence on the X-ray flux. This dependence can be exploited to obtain information on the volume occupied by the atoms that move in the glass following an absorption event. The length scale derived in this way, of the order of the nanometer, is consistent with that reported for the dynamical heterogeneities, suggesting the existence of a new scheme to get access to this fundamental quantity.