-rw-r--r-- | noncore/graphics/drawpad/drawpad.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/noncore/graphics/drawpad/drawpad.cpp b/noncore/graphics/drawpad/drawpad.cpp index 5c7e541..aae9ab0 100644 --- a/noncore/graphics/drawpad/drawpad.cpp +++ b/noncore/graphics/drawpad/drawpad.cpp @@ -486,7 +486,12 @@ void DrawPad::importPage() importDialog.showMaximized(); if (importDialog.exec() == QDialog::Accepted) { - m_pDrawPadCanvas->importPage(importDialog.selected()->file()); + const DocLnk* docLnk = importDialog.selected(); + + if (docLnk) { + m_pDrawPadCanvas->importPage(docLnk->file()); + delete docLnk; + } } } |