in reply to Error while trying to open a file
Don't feed junk to open?
$ perl -Mautodie -e"open my$in, q!<!, q!echo|! " Can't open 'echo|' for reading: 'Invalid argument' at -e line 1 [download]