Bugs item #1212812, was opened at 2005-06-01 15:35
Message generated for change (Comment added) made by simonmar
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1212812&group_id=8032

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: 6.4
>Status: Closed
Resolution: None
Priority: 5
Submitted By: Volker Stolz (volkersf)
Assigned to: Nobody/Anonymous (nobody)
Summary: Segfault on MVar-abuse

Initial Comment:
The attached program segfaults using 6.4 on FreeBSD at the 2nd 
takeMVar. Sorry, no HEAD to test with atm (I understand that the 
program might be strechting the limits a bit ;).
Other interesting effects can be observer, e.g. a rather unexpected 
"threads blocked indefinetely" when commenting out both lines (1) & 
(2) OR having both lines activated.

----------------------------------------------------------------------

>Comment By: Simon Marlow (simonmar)
Date: 2005-06-02 08:41

Message:
Logged In: YES 
user_id=48280

Not a bug - you're using unsafePerformIO to cast a String to
an Int, don't be surprised if you get a segfault!

The deadlock is also reasonable: if the main thread does a
takeMVar on an empty MVar, it blocks for ever, but the
runtime helpfully raises an exception rather than just hanging.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1212812&group_id=8032
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to