[lld] r252336 - Fix a few windows only tests.

Rafael Espindola via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 6 11:57:37 PST 2015


Author: rafael
Date: Fri Nov  6 13:57:37 2015
New Revision: 252336

URL: http://llvm.org/viewvc/llvm-project?rev=252336&view=rev
Log:
Fix a few windows only tests.

This argument must be non-null.

Modified:
    lld/trunk/COFF/DriverUtils.cpp

Modified: lld/trunk/COFF/DriverUtils.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/DriverUtils.cpp?rev=252336&r1=252335&r2=252336&view=diff
==============================================================================
--- lld/trunk/COFF/DriverUtils.cpp (original)
+++ lld/trunk/COFF/DriverUtils.cpp Fri Nov  6 13:57:37 2015
@@ -572,7 +572,9 @@ public:
     P += Sym.size() + 1;
     memcpy(P, DLLName.data(), DLLName.size());
 
-    object::Archive::Child C(Parent, Buf, nullptr);
+    std::error_code EC;
+    object::Archive::Child C(Parent, Buf, &EC);
+    assert(!EC && "We created an invalid buffer");
     return NewArchiveIterator(C, DLLName);
   }
 




More information about the llvm-commits mailing list