new helper: restore_saved_sigmask()