Method: FFI::Pointer.from_string_to_wide_string

Defined in:
lib/puppet/ffi/windows/api_types.rb

.from_string_to_wide_string(str, &block) ⇒ Object



27
28
29
30
31
32
33
# File 'lib/puppet/ffi/windows/api_types.rb', line 27

def self.from_string_to_wide_string(str, &block)
  str = Puppet::Util::Windows::String.wide_string(str)
  FFI::MemoryPointer.from_wide_string(str, &block)

  # ptr has already had free called, so nothing to return
  nil
end