Skip backup if project folder isn't writeable
Fixes https://gitlab.com/kicad/code/kicad/-/issues/7405
This commit is contained in:
parent
3ac5fd6342
commit
d25341901c
|
@ -1017,8 +1017,10 @@ bool SETTINGS_MANAGER::TriggerBackupIfNeeded( REPORTER& aReporter ) const
|
||||||
return dt;
|
return dt;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Project not saved yet
|
wxFileName projectPath( Prj().GetProjectPath() );
|
||||||
if( Prj().GetProjectPath().empty() )
|
|
||||||
|
// Skip backup if project path isn't valid or writeable
|
||||||
|
if( !projectPath.IsOk() || !projectPath.Exists() || !projectPath.IsDirWritable() )
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
wxString backupPath = GetProjectBackupsPath();
|
wxString backupPath = GetProjectBackupsPath();
|
||||||
|
|
Loading…
Reference in New Issue