mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-18 16:03:17 +00:00
[llvm-rtdyld] Refactor to reduce indentation.
Suggested by: David Blaikie. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@253808 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
085776b0a3
commit
e5dedf932d
@ -247,12 +247,11 @@ static int Error(const Twine &Msg) {
|
||||
|
||||
static void loadDylibs() {
|
||||
for (const std::string &Dylib : Dylibs) {
|
||||
if (sys::fs::is_regular_file(Dylib)) {
|
||||
std::string ErrMsg;
|
||||
if (sys::DynamicLibrary::LoadLibraryPermanently(Dylib.c_str(), &ErrMsg))
|
||||
report_fatal_error("Error loading '" + Dylib + "': " + ErrMsg);
|
||||
} else
|
||||
if (!sys::fs::is_regular_file(Dylib))
|
||||
report_fatal_error("Dylib not found: '" + Dylib + "'.");
|
||||
std::string ErrMsg;
|
||||
if (sys::DynamicLibrary::LoadLibraryPermanently(Dylib.c_str(), &ErrMsg))
|
||||
report_fatal_error("Error loading '" + Dylib + "': " + ErrMsg);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user