- if (theBufferList().close(lyx_view_->buffer(), true) && !quitting) {
- if (theBufferList().empty()) {
- // need this otherwise SEGV may occur while
- // trying to set variables that don't exist
- // since there's no current buffer
- lyx_view_->getDialogs().hideBufferDependent();
- } else {
- lyx_view_->setBuffer(theBufferList().first());
- }
- }