src/nnn.c | 10 +++++----- diff --git a/src/nnn.c b/src/nnn.c index 9ca0240dc7490efad7eb336dd010b7e22b9ddded..897c32f14cb837e7d513288b556c62a76b6adbb7 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -7734,11 +7734,6 @@ if (!(r == CTX_MAX || xconfirm(r))) break; // fallthrough } -#ifndef NOSSN - if (session && g_state.prstssn) - save_session(session, NULL); -#endif - /* CD on Quit */ tmp = getenv("NNN_TMPFILE"); if ((sel == SEL_QUITCD) || tmp) { @@ -8636,6 +8631,11 @@ if (sort) set_sort_flags(sort); opt = browse(initpath, session, pkey); + +#ifndef NOSSN + if (session && g_state.prstssn) + save_session(session, NULL); +#endif #ifndef NOMOUSE mousemask(mask, NULL);