http://www.perlmonks.org?node_id=655645


in reply to Problem to add a timeout to external calls on Win32

Take a look at timeout, alarm and perlipc.