From 7dbe4540196dcae10d728f8a15f3fa7c9225a650 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Wed, 22 Nov 2023 23:43:42 +0200 Subject: SL-17846 Crash at ~LLSearchEditor A weird crash inside LLSearchEditor, try clearing it explicitly --- indra/llui/llfiltereditor.h | 1 + indra/llui/llsearcheditor.cpp | 8 ++++++++ indra/llui/llsearcheditor.h | 2 +- 3 files changed, 10 insertions(+), 1 deletion(-) (limited to 'indra') diff --git a/indra/llui/llfiltereditor.h b/indra/llui/llfiltereditor.h index 3a05bc05a1..52cad3bff4 100644 --- a/indra/llui/llfiltereditor.h +++ b/indra/llui/llfiltereditor.h @@ -43,6 +43,7 @@ class LLFilterEditor : public LLSearchEditor public: struct Params : public LLInitParam::Block {}; + virtual ~LLFilterEditor() {} protected: LLFilterEditor(const Params&); diff --git a/indra/llui/llsearcheditor.cpp b/indra/llui/llsearcheditor.cpp index bafeef41fb..7a88ecc76f 100644 --- a/indra/llui/llsearcheditor.cpp +++ b/indra/llui/llsearcheditor.cpp @@ -104,6 +104,14 @@ LLSearchEditor::LLSearchEditor(const LLSearchEditor::Params& p) } } +LLSearchEditor::~LLSearchEditor() +{ + mSearchButton = NULL; + mClearButton = NULL; + mSearchEditor->deleteAllChildren(); + deleteAllChildren(); +} + //virtual void LLSearchEditor::draw() { diff --git a/indra/llui/llsearcheditor.h b/indra/llui/llsearcheditor.h index c0f3c1d60c..bd51988d07 100644 --- a/indra/llui/llsearcheditor.h +++ b/indra/llui/llsearcheditor.h @@ -74,7 +74,7 @@ protected: friend class LLUICtrlFactory; public: - virtual ~LLSearchEditor() {} + virtual ~LLSearchEditor(); /*virtual*/ void draw(); -- cgit v1.2.3