diff options
Diffstat (limited to 'lib/chef/win32/security/sid.rb')
-rw-r--r-- | lib/chef/win32/security/sid.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/win32/security/sid.rb b/lib/chef/win32/security/sid.rb index 9951b931c9..f6b88c60ce 100644 --- a/lib/chef/win32/security/sid.rb +++ b/lib/chef/win32/security/sid.rb @@ -279,7 +279,7 @@ class Chef status = NetUserEnum(servername, level, filter, bufptr, prefmaxlen, entriesread, totalentries, resume_handle) if status == NERR_Success || status == ERROR_MORE_DATA - entriesread.read_long.times.collect do |i| + Array.new(entriesread.read_long) do |i| user_info = USER_INFO_3.new(bufptr.read_pointer + i * USER_INFO_3.size) # Check if the account is the Administrator account # RID for the Administrator account is always 500 and it's privilage is set to USER_PRIV_ADMIN |