Simple "Hello World" Warp-based web server crashes on Ubuntu x86_64
Антон Десятов
anton.dessiatov at gmail.com
Tue Mar 1 15:24:59 UTC 2016
Hello dear GHC developers,
I have recently experienced what I believe to be a bug either in GHC or in
Warp library (if it is indeed in Warp then sorry for posting to wrong
mailing list). I've managed to shrink it to a few lines of code and publish
on a GitHub. Here is the link:
https://github.com/anton-dessiatov/warp-ghc-issue
What I wanted to do is to establish network connection in my code and then
at some point pass it to Warp for further processing. What I got is that
after successfully processing first HTTP request my program consumes 100%
CPU and eventually crashes with an error like this:
*** Error in
`/home/farnsworth/work/warp-ghc-issue/.stack-work/install/x86_64-linux/lts-5.5/7.10.3/bin/warp-ghc-issue':
double free or corruption (!prev): 0x00000000016214b0 ***
Aborted (core dumped)
When compiled with -debug I see another message:
repro: internal error: ASSERTION FAILED: file rts/Schedule.h, line 137
(GHC version 7.10.3 for x86_64_unknown_linux)
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
Aborted (core dumped)
I tried to debug it by enabling -dcore-lint and -debug in my
~/.stack/config.yaml and what worries me is that in this case Warp itself
doesn't compile (tried with 7.10.2 and 7.10.3) giving core lint failure in
Network.Wai.Handler.Warp.HTTP2.Worker. Not sure if it is relevant, but
looks suspicious.
Could anybody please try building my code on x64 Linux, run it, open
localhost:8080 in a web browser and confirm that there is indeed a bug?
Regards,
Anton.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20160301/a1bc12b5/attachment.html>
More information about the ghc-devs
mailing list