in reply to Can't update file
On this line:
if ( $md5row = $md5chksum ) {
... you just assigned the value that $md5chksum contains to $md5row, because = is an assignment operator, not a relational equality operator. The relational equality operators are == for numeric comparisons, and eq for string comparisons. See perlop for details. This is also covered briefly in perlintro.
Also, please remove every & that precedes a function call in your script unless you have a good reason for keeping it there. It's a bad habit because it actually alters the function call characteristics. This will be discussed in perlsub.
Dave
|
|---|