Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] GC and C
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Lauren A <museumprogrammer@y...>
Subject: [Caml-list] GC and C
I'm trying to call an already-written C function from
my OCaml code. I've written a wrapper for the C
function (in C) that calls CAMLparam on the incoming
arguments and uses CAMLreturn for the return value. 

Somewhere in the middle of my program, I get a seg
fault, which, when I use a debugger, looks like it's
coming from the garbage collector. Weirdly, when I
call Gc.compact() in my OCaml code-- either directly
before or after calling my C wrapper function-- I
don't get a seg fault and everything seems to work
properly.

Does anyone have any idea what might be going on?

Thank you very much,
Lauren


__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners