in reply to Failed to create a file
Slightly off topic, but related to coding style of sorts.
open(CFG, "C:\\TEMP\\cfg") || die "Failed to create cfg";You have included the parens in your call to open, which allows the ... || die ... to work as expected. If you leave off the parens - open CFG, "C:\\TEMP\\cfg" || die "Failed to create cfg";, this will give you the wrong results. Having stubbed my toe on this many times, I have made it my habit to use action or die instead of action || die.
--MidLifeXis
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Failed to create a file
by thezip (Vicar) on May 06, 2011 at 20:50 UTC | |
|
Re^2: Failed to create a file
by tchrist (Pilgrim) on May 06, 2011 at 13:29 UTC | |
by moritz (Cardinal) on May 09, 2011 at 12:58 UTC | |
by tchrist (Pilgrim) on May 09, 2011 at 18:18 UTC |