Browse Source

Don't try to load library with path == null

pull/1140/merge
Nikita Tsukanov 9 years ago
parent
commit
d4048de994
  1. 16
      src/Gtk/Avalonia.Gtk3/Interop/Resolver.cs

16
src/Gtk/Avalonia.Gtk3/Interop/Resolver.cs

@ -104,14 +104,16 @@ namespace Avalonia.Gtk3.Interop
var path = Custom?.Lookup(dll);
if (path == null && Custom?.BasePath != null)
path = Path.Combine(Custom.BasePath, name);
try
{
return loader.LoadLibrary(path);
}
catch (Exception e)
if (path != null)
{
exceptions.Add(e);
try
{
return loader.LoadLibrary(path);
}
catch (Exception e)
{
exceptions.Add(e);
}
}
throw new AggregateException("Unable to load " + dll, exceptions);
}

Loading…
Cancel
Save