[Mono-bugs] [Bug 423450] [Regression] Mono does not find library causing banshee to crash
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Mon Sep 8 14:48:33 EDT 2008
https://bugzilla.novell.com/show_bug.cgi?id=423450
User vargaz at gmail.com added comment
https://bugzilla.novell.com/show_bug.cgi?id=423450#c13
--- Comment #13 from Zoltan Varga <vargaz at gmail.com> 2008-09-08 12:48:33 MDT ---
How about this:
foreach (AssemblyName ref_name in asm.GetReferencedAssemblies
()) {
Assembly ref_asm = null;
try {
ref_asm = Assembly.Load (ref_name);
} catch (FileNotFoundException) {
// Try loading from the same directory as the
parent assembly,
// to simulate the normal assembly reference
loading rules
string path = Path.Combine
(Path.GetDirectoryName (asm.Location), (ref_name.Name + ".dll"));
ref_asm = Assembly.LoadFrom (path);
}
if (ref_asm != null)
Console.WriteLine ("FOUND: " + ref_asm);
else
Console.WriteLine ("NOT FOUND: " + ref_asm);
}
--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the mono-bugs
mailing list