… | … | ||
---|---|---|---|
14 | 14 | ||
15 | my $tmpfile = "/tmp/$filename"; | 15 | my $tmpfile = "/tmp/$filename"; |
16 | 16 | ||
17 | my $msg = "uploaded $filename"; | 17 | my $msg = "uploaded $filename"; |
18 | 18 | ||
19 | if (open my $o, ">" . $tmpfile) { | 19 | if (open my $o, ">$tmpfile") { |
20 | chmod 0644, $tmpfile; | ||
20 | print $o $txt; | 21 | print $o $txt; |
21 | close $o; | 22 | close $o; |
22 | } else { | 23 | } else { |
23 | $msg = "couldn't write $tmpfile: $!"; | 24 | $msg = "couldn't write $tmpfile: $!"; |
24 | } | 25 | } |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |