From 0b8cfef8b5407cb8d1f7afcf4384d1f0decbf09d Mon Sep 17 00:00:00 2001 From: Laurent Montel Date: Sun, 23 Aug 2020 15:18:58 +0200 Subject: [PATCH] Fix crash when we call "save attachments" BUG: 425532 FIXED-IN: 5.15.1 --- src/kmmainwidget.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/kmmainwidget.cpp b/src/kmmainwidget.cpp index 7d5d56cc1..45fe9e9f6 100644 --- a/src/kmmainwidget.cpp +++ b/src/kmmainwidget.cpp @@ -2340,6 +2340,9 @@ void KMMainWidget::slotSaveAttachments() if (selectedMessages.isEmpty()) { return; } + if (!mMsgView) { + return; + } // Avoid re-downloading in the common case that only one message is selected, and the message // is also displayed in the viewer. For this, create a dummy item without a parent collection / item id, // so that KMCommand doesn't download it.