in reply to Re: file dies instantly
in thread file dies instantly

Furthermore, if you use die you can add a sub reference into $SIG{__DIE__} (see die's documentation) that will be called just before the error processing is done. Which means you can add that "wait for user input" behaviour for several die calls at once. You can limit that modification to a dynamic scope with local.

Be sure not to call exit in the sub that will be called when dieing, or else you might just as well have never died.