Fix assertion in symbol library remap dialog.
Do not attempt to normalize environment variables that are not valid paths, paths that do not exist, or paths that the user does not have read access to. Fixes lp:1731655 https://bugs.launchpad.net/kicad/+bug/1731655
This commit is contained in:
parent
370c3b068b
commit
41a9007b6d
|
@ -136,6 +136,11 @@ void DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable( REPORTER& aReporter )
|
|||
|
||||
for( auto& entry : envMap )
|
||||
{
|
||||
// Don't bother normalizing paths that don't exist or the user cannot read.
|
||||
if( !wxFileName::DirExists( entry.second.GetValue() )
|
||||
|| !wxFileName::IsDirReadable( entry.second.GetValue() ) )
|
||||
continue;
|
||||
|
||||
envPath.SetPath( entry.second.GetValue() );
|
||||
|
||||
if( normalizeAbsolutePaths( envPath, fn, &tmp ) )
|
||||
|
|
Loading…
Reference in New Issue