Commit 5be11ad9 authored by Méven Car's avatar Méven Car Committed by Christoph Cullmann
Browse files

Avoid errors like 'QDir::mkdir: Empty or null file name'

parent 04d5e019
......@@ -416,12 +416,16 @@ void KateDocManager::saveDocumentList(KConfig *config)
// prepare stash directory
const QString appDataPath = QStandardPaths::writableLocation(QStandardPaths::AppDataLocation);
const QString sessionName = KateApp::self()->sessionManager()->activeSession()->name();
QDir dir(appDataPath);
const auto session = KateApp::self()->sessionManager()->activeSession();
if (session) {
const QString sessionName = session->name();
int i = 0;
for (KTextEditor::Document *doc : qAsConst(m_docList)) {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment