in reply to Re^2: Help with exercise
in thread Help with exercise
Although, to tell the full truth, I am not sure I would really check the chdir return status after I have checked that $dir contains a valid directory entry in the current directory (I know it might still fail for various reasons, such as missing privileges, but this is quite unlikely in my context and, sometimes, there is a trade-off between code complexity and coding efficiency). Or I might probably use the autodie module in such a context with a lot of system calls.
Update: or, as suggested by Random_Walk, we might go the other way around and let chdir do the checks.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Help with exercise
by karlgoethebier (Abbot) on Sep 24, 2017 at 16:11 UTC |