fix a second segmentation fault