Reduce indentation.
llvm-svn: 320433
diff --git a/lld/wasm/Driver.cpp b/lld/wasm/Driver.cpp
index 3fb6321..1ba07df 100644
--- a/lld/wasm/Driver.cpp
+++ b/lld/wasm/Driver.cpp
@@ -298,8 +298,6 @@
   // Make sure we have resolved all symbols.
   if (!Config->Relocatable && !Config->AllowUndefined) {
     Symtab->reportRemainingUndefines();
-    if (errorCount())
-      return;
   } else {
     // When we allow undefined symbols we cannot include those defined in
     // -u/--undefined since these undefined symbols have only names and no
@@ -311,6 +309,8 @@
         error("function forced with --undefined not found: " + Sym->getName());
     }
   }
+  if (errorCount())
+    return;
 
   if (!Config->Entry.empty() && !Symtab->find(Config->Entry)->isDefined())
     error("entry point not found: " + Config->Entry);