mirror of
https://github.com/webmin/webmin.git
synced 2026-02-03 14:13:29 +00:00
Switch all calls to open() to explicitly open for read
This commit is contained in:
@@ -495,7 +495,7 @@ else {
|
||||
}
|
||||
|
||||
# Validate archive
|
||||
open(FILE, $file);
|
||||
open(FILE, "<".$file);
|
||||
my $two;
|
||||
read(FILE, $two, 2);
|
||||
close(FILE);
|
||||
@@ -537,7 +537,7 @@ my %mfiles;
|
||||
my @files;
|
||||
while($m = readdir(DIR)) {
|
||||
next if ($m eq "." || $m eq ".." || !$hasmod{$m});
|
||||
open(MAN, "$manifests_dir/$m");
|
||||
open(MAN, "<$manifests_dir/$m");
|
||||
my @mfiles;
|
||||
while(<MAN>) {
|
||||
s/\r|\n//g;
|
||||
|
||||
@@ -49,7 +49,7 @@ else {
|
||||
}
|
||||
print "Content-type: application/x-gzip\n\n";
|
||||
my $buf;
|
||||
open(TEMP, $temp);
|
||||
open(TEMP, "<$temp");
|
||||
while(read(TEMP, $buf, 1024)) {
|
||||
print $buf;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user