summaryrefslogtreecommitdiff
path: root/lib/tempfile.rb
diff options
context:
space:
mode:
author(no author) <(no author)@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-09-08 07:09:52 +0000
committer(no author) <(no author)@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-09-08 07:09:52 +0000
commitb1f96af92f5b8519c477de3bd8917e5220442f6b (patch)
treec29d1f6370f4498547c80a69e0440256eeaf39e7 /lib/tempfile.rb
parent48acbc5e03622f1eb0423a6c2a3a603f61acfac6 (diff)
This commit was manufactured by cvs2svn to create tag 'v1_1d-start'.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/tags/v1_1d-start@299 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/tempfile.rb')
-rw-r--r--lib/tempfile.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/tempfile.rb b/lib/tempfile.rb
index 2de1ebddf3..bf51ac2788 100644
--- a/lib/tempfile.rb
+++ b/lib/tempfile.rb
@@ -22,7 +22,7 @@ class Tempfile < SimpleDelegator
File.unlink(path)
end
if File.exist?(path + '.lock')
- File.rmdir(path + '.lock')
+ Dir.rmdir(path + '.lock')
end
print "done\n" if $DEBUG
}
@@ -51,8 +51,8 @@ class Tempfile < SimpleDelegator
@clean_files = Tempfile.callback(tmpname)
ObjectSpace.define_finalizer(self, @clean_files)
- @tmpname = tmpname
@tmpfile = File.open(tmpname, 'w+')
+ @tmpname = tmpname
super(@tmpfile)
Dir.rmdir(lock)
ensure