mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 11:16:55 +00:00
use is_writable to check if the copy_file will work
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9934 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d33531c567
commit
a087bda7ec
@ -1,3 +1,8 @@
|
||||
2005-05-11 Lars Gullik Bjonnes <larsbj@gullik.net>
|
||||
|
||||
* buffer.C (save): check if destination is writable before trying
|
||||
to copy a file
|
||||
|
||||
2005-05-11 Martin Vermeer <martin.vermeer@hut.fi>
|
||||
|
||||
* BufferView_pimpl.C (update): fix processEvents -caused update
|
||||
|
@ -707,7 +707,7 @@ bool Buffer::save() const
|
||||
// good enough. (Lgb)
|
||||
// But to use this we need fs::copy_file to actually do a copy,
|
||||
// even when the target file exists. (Lgb)
|
||||
if (fs::exists(fileName())) {
|
||||
if (fs::exists(fileName()) && fs::is_writable(fs::path(fileName()).branch_path())) {
|
||||
//try {
|
||||
fs::copy_file(fileName(), s, false);
|
||||
//}
|
||||
|
Loading…
Reference in New Issue
Block a user