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


in reply to Bad file descriptor after vmran command using system()

Your expectations for the return value of system are not correct. It returns 0 in the case of success, and therefore your test should look like:

system( ... ) == 0 or die "System failed: $?, $!"

--MidLifeXis

Replies are listed 'Best First'.
Re^2: Bad file descriptor after vmran command using system()
by Ingvar (Novice) on Apr 08, 2013 at 13:10 UTC

    It works now! Thank you all!