home *** CD-ROM | disk | FTP | other *** search
/ Borland Programmer's Resource / Borland_Programmers_Resource_CD_1995.iso / ntcode / ntperlb / t / op / fork.nt < prev    next >
Encoding:
Text File  |  1995-05-19  |  292 b   |  18 lines

  1. #!./perl
  2.  
  3. # $Header: fork.t,v 4.0 91/03/20 01:52:43 lwall Locked $
  4.  
  5. $| = 1;
  6. print "1..0\n";
  7. exit;
  8.  
  9. if ($cid = fork) {
  10.     sleep 2;
  11.     if ($result = (kill 9, $cid)) {print "ok 2\n";} else {print "not ok 2 $result\n";}
  12. }
  13. else {
  14.     $| = 1;
  15.     print "ok 1\n";
  16.     sleep 10;
  17. }
  18.