$SIG{INT} = 'IGNORE';    #Cause Ctrl-C to have no effect... Use with
caution...

Or,
$SIG{INT} = \&tsktsk;

sub tsktsk {
    $SIG{INT} = \&tsktsk;
    warn "\aStop playing with the keyboard.\n";
}


From:  Perl Cookbook, recipe 16.18. Catching Ctrl-C, page 589


Bob
----- Original Message -----
From: "Ferenc Tamas Gyurcsan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, February 14, 2000 10:22 AM
Subject: Re: perl question


> Hi,
>
> >external command, but in order to deal with ctrl+c, you'll have to trap
the
> >key sequence yourself, and deal with it elsewhere in your code.
> Maybe signal handling would help? Can't send any code though. Check out
which
> signal Ctrl+C generates, and then you have to handle that.
>
> Ferenc
>
> **********************************************************
> To unsubscribe from this list, send mail to
> [EMAIL PROTECTED] with the following text in the
> *body* (*not* the subject line) of the letter:
> unsubscribe gnhlug
> **********************************************************



**********************************************************
To unsubscribe from this list, send mail to
[EMAIL PROTECTED] with the following text in the
*body* (*not* the subject line) of the letter:
unsubscribe gnhlug
**********************************************************

Reply via email to