ExternalLibrary and lots of arguments

Pupeno pupeno at pupeno.com
Thu Nov 11 21:07:08 PST 2004


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello Slaters,
I am using ExternalLibrary to build a wrapper for XLib (just what I need to 
get Cairo going). There's a function with nine arguments that I need to call:

Window XCreateSimpleWindow ( Display *display , Window parent , int x , int 
y , unsigned int width , unsigned int height , unsigned int border_width , 
unsigned long border , unsigned long background ); 

and it was not behaving like expected. It alwasy returned Nil, Nil, Nil, so I 
started checking out EXternalLibrary's C side and I've found it couldn't pass 
more than 5 parameters. So, for my needs I extended to 12 [1] parameters and 
the patch is attached.
Now, instead of getting Nil, I get a segfault... progress... :) I'm rebuilding 
the vm and the image in case that changes something, and if not... well... 
probably it is time to use gdb and see what's going on.
- -- 
Pupeno: pupeno at pupeno.com - http://www.pupeno.com

[1] To be able to call this beast: 
Window XCreateWindow ( Display *display , Window parent , int x , int y , 
unsigned int width , unsigned int height , unsigned int border_width , int 
depth , unsigned int class , Visual *visual , unsigned long valuemask , 
XSetWindowAttributes *attributes ); 
when the time comes.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)

iD8DBQFBlEUAfW48a9PWGkURAp6hAJ0fMR459W025bG7gbxgvcbQUIZzgQCeOn3W
JVBtLmfwT+EaqFcxJ66PAqw=
=ZvLH
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: extprim.c.morearguments.patch
Type: text/x-diff
Size: 3431 bytes
Desc: not available
Url : /archives/slate/attachments/20041112/5860a6ae/extprim.c.morearguments.bin


More information about the Slate mailing list