[PATCH] D28107: [ELF] - Do not create huge garbage files on section offset overflow.

George Rimar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 17 06:01:39 PST 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL292219: [ELF] - Do not create huge garbage files on section offset overflow. (authored by grimar).

Changed prior to commit:
  https://reviews.llvm.org/D28107?vs=82475&id=84663#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D28107

Files:
  lld/trunk/ELF/Writer.cpp


Index: lld/trunk/ELF/Writer.cpp
===================================================================
--- lld/trunk/ELF/Writer.cpp
+++ lld/trunk/ELF/Writer.cpp
@@ -217,6 +217,9 @@
     fixAbsoluteSymbols();
   }
 
+  // It does not make sense try to open the file if we have error already.
+  if (ErrorCount)
+    return;
   // Write the result down to a file.
   openFile();
   if (ErrorCount)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28107.84663.patch
Type: text/x-patch
Size: 393 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170117/baf73f75/attachment.bin>


More information about the llvm-commits mailing list