summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/webrick/httpauth/htdigest.rb4
-rw-r--r--lib/webrick/httpauth/htgroup.rb4
-rw-r--r--lib/webrick/httpauth/htpasswd.rb4
3 files changed, 6 insertions, 6 deletions
diff --git a/lib/webrick/httpauth/htdigest.rb b/lib/webrick/httpauth/htdigest.rb
index 1b42c02dfa..c35b38433b 100644
--- a/lib/webrick/httpauth/htdigest.rb
+++ b/lib/webrick/httpauth/htdigest.rb
@@ -40,7 +40,7 @@ module WEBrick
@digest = Hash.new
@mutex = Thread::Mutex::new
@auth_type = DigestAuth
- open(@path,"a").close unless File::exist?(@path)
+ File.open(@path,"a").close unless File.exist?(@path)
reload
end
@@ -51,7 +51,7 @@ module WEBrick
mtime = File::mtime(@path)
if mtime > @mtime
@digest.clear
- open(@path){|io|
+ File.open(@path){|io|
while line = io.gets
line.chomp!
user, realm, pass = line.split(/:/, 3)
diff --git a/lib/webrick/httpauth/htgroup.rb b/lib/webrick/httpauth/htgroup.rb
index 832ae8bd04..399a62c37f 100644
--- a/lib/webrick/httpauth/htgroup.rb
+++ b/lib/webrick/httpauth/htgroup.rb
@@ -36,7 +36,7 @@ module WEBrick
@path = path
@mtime = Time.at(0)
@group = Hash.new
- open(@path,"a").close unless File::exist?(@path)
+ File.open(@path,"a").close unless File.exist?(@path)
reload
end
@@ -46,7 +46,7 @@ module WEBrick
def reload
if (mtime = File::mtime(@path)) > @mtime
@group.clear
- open(@path){|io|
+ File.open(@path){|io|
while line = io.gets
line.chomp!
group, members = line.split(/:\s*/)
diff --git a/lib/webrick/httpauth/htpasswd.rb b/lib/webrick/httpauth/htpasswd.rb
index 8c7b09463b..976eeeb13e 100644
--- a/lib/webrick/httpauth/htpasswd.rb
+++ b/lib/webrick/httpauth/htpasswd.rb
@@ -40,7 +40,7 @@ module WEBrick
@mtime = Time.at(0)
@passwd = Hash.new
@auth_type = BasicAuth
- open(@path,"a").close unless File::exist?(@path)
+ File.open(@path,"a").close unless File.exist?(@path)
reload
end
@@ -51,7 +51,7 @@ module WEBrick
mtime = File::mtime(@path)
if mtime > @mtime
@passwd.clear
- open(@path){|io|
+ File.open(@path){|io|
while line = io.gets
line.chomp!
case line