From 54d7ede54447e7837b5b697bd919f895649c5e50 Mon Sep 17 00:00:00 2001 From: Erlend Aasland Date: Fri, 11 Jan 2008 02:14:34 +0100 Subject: [PATCH] Fix issue 542: Harden Grob::relative_coordinate() --- lily/grob.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lily/grob.cc b/lily/grob.cc index fbb4683f4a..7f78b5ff60 100644 --- a/lily/grob.cc +++ b/lily/grob.cc @@ -265,7 +265,8 @@ Grob::translate_axis (Real y, Axis a) Real Grob::relative_coordinate (Grob const *refp, Axis a) const { - if (refp == this) + /* eaa - hmmm, should we do a programming_error() here? */ + if ((this == NULL) || (refp == this)) return 0.0; /* We catch PARENT_L_ == nil case with this, but we crash if we did -- 2.39.5