Crash in unit tests on AMD64

Bug #380709 reported by wflu
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
clisp (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: clisp

A unittest in "tests/ffi.tst" (found in the clisp source package) segfaults in 64bit Ubuntu. Specifically, it seems like the following lines provokes the problem:
----
(progn
  (defparameter *x* 0)
  (defun callback (x)
    (the (unsigned-byte 16) x)
    (setf *x* x)
    (the (unsigned-byte 16) (1+ (* 2 x))))
  *x*)
0

(def-c-type idfun
 (c-function (:arguments (x uint)) (:return-type uint)
   (:language :stdc)))
IDFUN

;; convert forth and back
(type-of (setq callbackf (with-c-var (x 'idfun #'callback) x)))
FOREIGN-FUNCTION

(list (funcall callbackf 32767) *x*)
(65535 32767)
----

Revision history for this message
sds (sds-gnu) wrote :

this is probably because clisp is linked against the old libffcall.
https://bugs.launchpad.net/bugs/274951
re-linking new clisp against new libffcall should fix the problem.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.