Doublefree: Fixed FP when exit() is called