[Vm-dev] discuss: [Squeak 0001144]: [ENH] SmartSyntaxInterpreterPlugin

Martin Kuball martinkuball at web.de
Sat Aug 19 19:17:11 UTC 2006


I know this is more than a year in the past. But some things take 
their time and I'v just now resumed my work on the Xvid plugin. 

When evaluating my sugested changes, Andreas made the following 

> The main reason for concern is that this creates a dangerous
> precedent for plugins. Thus far, all plugins have been "safe" in
> such that they were used with unforgeable object references.
> Allowing arbitrary pointers in *plugin* interfaces means that the
> whole idea of "plugins are secure, FFI is not" becomes moot.    
> Suddenly we need to be aware which plugins abuse what pointers and I
> think we should really avoid this. I have not looked at the specific
> reason for wanting to pass a pointer instead of an object reference 
> but the only reason I can imagine is that the pointer was
> originally obtained by some FFI call. In which case I'd say "stick
> with FFI" instead of plugins (after all it's no harder to export a C
> function from a plugin than to write the named primitive).
> There are no good reasons that I can think of to suddenly start
> using C pointers in plugins (lazyness on behalf of the plugin writer
> does not count) and there are many good reasons against it.

Unfortunately I do not realy understand his arguments. From the code 
of the plugins that come with VMMaker I can see that there are 
plugins that use c-pointers and do pass them to smalltalk. E.g. the 
Mpeg3 Plugin does it and the OsProecess plugin is another example. 

I would be very glad if someone could explain to me what is allowed 
and what is forbidden regarding this matter.



More information about the Vm-dev mailing list