Subject: [clisp-list] Problem with gdi on clisp 2.30

From: [email-masked]
Date: Wed Nov 6 15:45:04 2002

The code I wrote for 2.28 has a problem on 2.30.
The problem is the code goes into a lisp stack overflow loop.
Does anyone see anything wrong with the following?
I have narrowed it down to the following call:

     pushSTACK(allocate_fpointer(hWnd));
     funcall(O(onCreate),1); // fails in this call

The onCreate variable is set by passing in a function in my
initialization lisp code as follows:

(defun init-gdi () (gdi::initc *functions* #'onCreate))
(defvar *hinstance* (init-gdi))

Following is the c code that is executed for initialization:
DEFVAR(functions,`nil`)
DEFVAR(localCons,`nil`)
DEFVAR(onCreate,`nil`)
DEFUN( GDI:INITC, h f)
{
  O(localCons) = allocate_cons();
  O(onCreate) = popSTACK();
  O(functions) = popSTACK();
  value1 = allocate_fpointer(GetModuleHandle(0));
  mv_count=1;
  return;
}