From: Axel S. <si...@co...> - 2009-11-22 22:26:39
|
Sun Nov 22 17:22:24 EST 2009 Axe...@en... * Remove the use of weak reference from gstreamer. As a temporary hack I removed the code to clean up a function closure. The old code relied on GWeakRef which has been removed from GObject due to the GC being able to finalize GObjects directly which will make GWeakRefs trigger callbacks into Haskell land form the unsafe GC. hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 243 -weakNotifyQuark, funPtrQuark :: Quark -weakNotifyQuark = unsafePerformIO $ quarkFromString "Gtk2HS::SyncHandlerWeakNotify" +-- Note: I've removed this magic since GWeakNotify had to moved out of +-- GObject since GObject can be finalized directly from the Haskell GC +-- which can (and will in the case below) callbacks into Haskell that +-- will make the program abort. We're leaking the function closure instead. +--weakNotifyQuark, +funPtrQuark :: Quark +--weakNotifyQuark = unsafePerformIO $ quarkFromString "Gtk2HS::SyncHandlerWeakNotify" hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 252 +{- hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 263 +-} hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 281 +{- hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 287 +-} hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 313 +{- [_$_] hunk ./gstreamer/Media/Streaming/GStreamer/Core/Bus.chs.pp 316 +-} |