mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-23 02:14:50 +00:00
Fix bug #6491: Empty .emergency file causes crash.
If the load fails, we should not try to save an emergency file as the file was not yet fully loaded and weird things may happen. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33294 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d49438e76c
commit
f0c386fa6b
@ -93,6 +93,8 @@ Buffer * checkAndLoadLyXFile(FileName const & filename, bool const acceptDirty)
|
||||
return 0;
|
||||
}
|
||||
if (!b->loadLyXFile(filename)) {
|
||||
// do not save an emergency file when releasing the buffer
|
||||
b->markClean();
|
||||
theBufferList().release(b);
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user