From: David Kastrup Date: Fri, 19 Sep 2014 10:14:28 +0000 (+0200) Subject: Issue 4116: Disable ASSERT_LIVE_IS_ALLOWED in GUILEv2 X-Git-Tag: release/2.19.15-1~13 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=46173612585e09fbad842963aaf61ac9f86317e5;p=lilypond.git Issue 4116: Disable ASSERT_LIVE_IS_ALLOWED in GUILEv2 Apparently the garbage collection in GUILEv2 can do a mark pass over material without actually protecting it from collection, possibly because the garbage collector can run in a separate thread. At least, the attempt to print such remaining live smobs still seen by a mark pass leads to crashes, so disable this memory leak detection mechanism on GUILEv2. --- diff --git a/lily/include/smobs.hh b/lily/include/smobs.hh index 373bf77c6f..c3a9f4bf4c 100644 --- a/lily/include/smobs.hh +++ b/lily/include/smobs.hh @@ -293,7 +293,12 @@ public: static SCM readout (); }; -#ifndef NDEBUG +// This does not appear to work with GUILEv2's garbage collector: +// Objects are found in the GC phase but printing them will crash at +// least some, so they are apparently not protected in spite of being +// included in the GC scans. So it would appear that scanning smobs +// is not equivalent to marking them. Ugh. +#if !defined(NDEBUG) && !GUILEV2 #define ASSERT_LIVE_IS_ALLOWED(arg) \ do { \ static parsed_dead pass_here; \