Space charge in ionization detectors and the NA48 electromagnetic calorimeter