[Openmcl-devel] Crash on allocating new pointer
Andrew P. Lentvorski, Jr.
bsder at mail.allcaps.org
Fri Jul 2 03:03:11 PDT 2004
On Jul 1, 2004, at 6:32 PM, Gary Byers wrote:
> There's a call to #_gtk_init in "ccl:library;openmcl-gtk-support.lisp";
> you might find that helpful (especially in the context of the long
> I sent last night.)
Well, I had looked at that before, but that fact that none of the
example code actually calls it is a bit disconcerting.
However, I forged ahead and borrowed the gtk-init function and
substituted an ff-call. I wound up with another unhandled exception:
Welcome to OpenMCL Version (Beta: Darwin) 0.14.2-040506!
? (setf gtk-lib (open-shared-library
#<SHLIB /Users/devel/lib/libgtk-x11-2.0.dylib #x638EEEE>
? (setq gi (external "_gtk_init"))
#<EXTERNAL-ENTRY-POINT "_gtk_init" (#x0152251C)
? (defun gtk-init (arg &rest args)
(declare (dynamic-extent args))
(push arg args)
(with-string-vector (argv args)
(rlet ((argvp (* t))
(setf (%get-ptr argvp) argv
(%get-long argcp) (length args))
(ff-call (external "_gtk_init") :address argcp :address argvp))))
? (gtk-init '"junk1" '"junk2")
Unhandled exception 4 at 0x0638ed84, context->regs at #xf01356a8
Illegal instruction (0x0600c9be) at 0x0638ed84 In foreign code at
? for help
 OpenMCL kernel debugger:
What should that ff-call look like?
More information about the Openmcl-devel