How to return via buffers using FFI?

ned at ned at
Sat Jan 28 03:57:01 UTC 2012

I'm trying to get some Win32 registry functions to work with FFI.
But I'm apparently not doing it right.

The one function that I have in here returns several values via
pointers. Two are strings; the string buffers are filled, and DWORD
values are set to the length of the returned strings.

One is a structure (a Win32FileTime here).

However, when I try this apicall I get an error saying "Can't coerce

What am I doing wrong?


from preamble:

"Change Set:		Win32Registry-nk
Date:			7 September 2002
Author:			Ned Konz

This is the start of a package that will allow access
to the Windows registry from Squeak using FFI.

However, it doesn't work yet.


Win32RegistryKey testRegEnumKeyEx

and you will see that it can't coerce arguments.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: Win32Registry-nk.cs.gz
Type: application/octet-stream
Size: 1086 bytes
Desc: not available
Url :

More information about the Squeak-dev mailing list