ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/AnyEvent/t/02_signals.t
Revision: 1.1
Committed: Sun Dec 10 23:59:15 2006 UTC (17 years, 6 months ago) by root
Content type: application/x-troff
Branch: MAIN
Log Message:
implement sigwatcher

File Contents

# Content
1 $|=1;
2 BEGIN { print "1..5\n" }
3
4 use AnyEvent;
5
6 print "ok 1\n";
7
8 my $cv = AnyEvent->condvar;
9
10 my $sw = AnyEvent->signal (signal => 'CHLD', cb => sub {
11 print "ok 3\n";
12 $cv->broadcast;
13 });
14
15 print "ok 2\n";
16 kill 'CHLD', 0;
17 $cv->wait;
18
19 undef $sw;
20
21 print "ok 4\n";
22
23 kill 'CHLD', 0;
24
25 print "ok 5\n";