diff --git a/src/richtext/richtextbuffer.cpp b/src/richtext/richtextbuffer.cpp index e18b39c433..70d37ef6d5 100644 --- a/src/richtext/richtextbuffer.cpp +++ b/src/richtext/richtextbuffer.cpp @@ -8317,6 +8317,8 @@ bool wxRichTextBuffer::SubmitAction(wxRichTextAction* action) { GetCommandProcessor()->Store(cmd); // Just store it, without Do()ing anything } + else + delete cmd; } return true;