Object
# File lib/chef/util/windows.rb, line 46 def dword_to_i(buffer, offset) buffer[offset*PTR_SIZE,PTR_SIZE].unpack('i')[0] || 0 end
# File lib/chef/util/windows.rb, line 40 def lpwstr_to_s(buffer, offset) str = 0.chr * (256 * 2) #XXX unhardcode this length (*2 for WCHAR) wcscpy str, buffer[offset*PTR_SIZE,PTR_SIZE].unpack('L')[0] wide_to_multi str end
return pointer for use with pack('L')
# File lib/chef/util/windows.rb, line 51 def str_to_ptr(v) [v].pack('p*').unpack('L')[0] end
[Validate]
Generated with the Darkfish Rdoc Generator 2.