]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/protected-scm.cc
release: 1.1.28
[lilypond.git] / lily / protected-scm.cc
index 0cc85e14d5d7959f34f59cfaaf489c12d67129d9..ebd69cb77c4aaf45c6797681d75b74cf69ef8caf 100644 (file)
@@ -43,10 +43,13 @@ Protected_scm::operator =(Protected_scm const &s)
 Protected_scm::~Protected_scm ()
 {
   if  (object_)
-    scm_unprotect_object (object_);
+    {
+      scm_unprotect_object (object_);
+      object_ =0L;             // be nice to conservative GC
+    }
 }
 
-Protected_scm::operator SCM ()
+Protected_scm::operator SCM () const
 {
   return object_;
 }