Fix check_tempfile_leak in leakchecker.rb
The instance variable @tmpfile was removed in ddcfc9f so check_tempfile_leak did not work.
This commit is contained in:
parent
57e3fc32ea
commit
cf3b62b545
Notes:
git
2024-09-05 18:03:58 +00:00
@ -155,8 +155,8 @@ class LeakChecker
|
||||
if prev_count == count
|
||||
[prev_count, []]
|
||||
else
|
||||
tempfiles = ObjectSpace.each_object(Tempfile).find_all {|t|
|
||||
t.instance_variable_defined?(:@tmpfile) and t.path
|
||||
tempfiles = ObjectSpace.each_object(Tempfile).reject {|t|
|
||||
t.instance_variables.empty? || t.closed?
|
||||
}
|
||||
[count, tempfiles]
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user