Looks like a ghc problem (with 4.04, at least) - Cc'ing the
ghc-bugs list in case anyone there wants to track down why
(nfib 20) crashes when called via 'foreign export' (the
program in question can be found in hdirect/examples/server/.)

The base case in the defn of nfib used in that sample is wrong,
btw :)

--sigbjorn

J.T.Bradley <[EMAIL PROTECTED]> writes:
> 
> I was playing around with the the server example in the hdirect-0.16
> distribution and discovered that if you increase the nfib 
> argument from
> something low to say 20 then the fac call will seg fault.
> 
> ie instead of getting:
> 
> nfib(20) = 17710
> fac(14)  = 1278945280
> 
> you get:
> 
> nfib(20) = 17710
> zsh: segmentation fault  ./tst
> 
> ...some sort of memory leak maybe?
> 
> Config: hdirect-0.16, ghc4.04, egcs-2.91.66, glibc-2.1.2, x86-linux
> 
> --Jeremy.
> 

Reply via email to