Project

General

Profile

Actions

Feature #7526

closed

infinit loop in Registry::each_value

Added by rubyhack (first last) about 12 years ago. Updated about 7 years ago.

Status:
Closed
Target version:
[ruby-core:50627]

Description

in win32/registry.rb :
begin
type, data = read(subkey)
rescue Error
next
end
the correction :
rescue Error
index += 1
next
end

I think that using Registry::info to get the number of values (also number of subkeys in each_key)
is a better solution so to skip problematic values.

also a limitation in Registry::read
when REG_BINARY
[ type, data ]

should be :
when REG_BINARY, REG_NONE, REG_LINK, REG_RESOURCE_LIST, REG_RESOURCE_REQUIREMENTS_LIST
[ type, data ]

instead of raising an exception for those types (in regedit.exe REG_NONE is equivalent to REG_BINARY)

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0