Method: FFI::Pointer#read_utf16string
- Defined in:
- lib/chef/win32/unicode.rb
#read_utf16string ⇒ Object
52 53 54 55 56 |
# File 'lib/chef/win32/unicode.rb', line 52 def read_utf16string offset = 0 offset += 2 while get_bytes(offset, 2) != "\x00\x00" get_bytes(0, offset).force_encoding("utf-16le").encode("utf-8") end |