See post above about removing the print line.
In reply to Re^3: I need some help with open2 by Joost in thread I need some help with open2 by Anonymous Monk