From f610b4b509013a6c9ef448385575ade01733559c Mon Sep 17 00:00:00 2001 From: Po Lu Date: Wed, 1 Jun 2022 05:05:42 +0000 Subject: [PATCH] Fix creation of menu items without help text on Haiku * src/haiku_support.cc (EmacsMenuItem): Don't mistakenly assume help is non-NULL. --- src/haiku_support.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/haiku_support.cc b/src/haiku_support.cc index 2411a7b539b..3b1a2cfcb38 100644 --- a/src/haiku_support.cc +++ b/src/haiku_support.cc @@ -2403,7 +2403,8 @@ public: if (key_label) key = strdup (key_label); - this->help = strdup (help); + if (help) + this->help = strdup (help); } ~EmacsMenuItem () -- 2.39.2