<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Jul 11, 2017 at 4:04 PM, Reid Kleckner <span dir="ltr"><<a href="mailto:rnk@google.com" target="_blank">rnk@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="">On Tue, Jul 11, 2017 at 3:42 PM, Rui Ueyama <span dir="ltr"><<a href="mailto:ruiu@google.com" target="_blank">ruiu@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><div class="m_6945448534154189616h5"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">-static bool remapTypesInSymbolRecord(Objec<wbr>tFile *File,<br>
+static void remapTypesInSymbolRecord(Objec<wbr>tFile *File,<br>
                                      MutableArrayRef<uint8_t> Contents,<br>
                                      ArrayRef<TypeIndex> TypeIndexMap,<br>
                                      ArrayRef<TiReference> TypeRefs) {<br>
   for (const TiReference &Ref : TypeRefs) {<br>
     unsigned ByteSize = Ref.Count * sizeof(TypeIndex);<br>
-    if (Contents.size() < Ref.Offset + ByteSize) {<br>
-      log("ignoring short symbol record");<br>
-      return false;<br>
-    }<br>
+    if (Contents.size() < Ref.Offset + ByteSize)<br>
+      fatal("ignoring short symbol record");<br></blockquote><div><br></div></div></div><div>If you use `fatal`, it doesn't ignore records but exits immediately.</div></div></div></div></blockquote><div><br></div></span><div>This is intentional. A short record is more indicative of data corruption than an invalid type index. An invalid type index probably means we just can't find the PDB. </div></div></div></div>
</blockquote></div><br></div><div class="gmail_extra">The error message is a bit confusing, isn't it? It says "ignoring" but what it does is to abort immediately.</div></div>