diff options
Diffstat (limited to 'lily/protected-scm.cc')
-rw-r--r-- | lily/protected-scm.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lily/protected-scm.cc b/lily/protected-scm.cc index 0cc85e14d5..ebd69cb77c 100644 --- a/lily/protected-scm.cc +++ b/lily/protected-scm.cc @@ -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_; } |