<div dir="ltr">It would be good if we have a test for this.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Nov 4, 2013 at 11:40 AM, Simon Atanasyan <span dir="ltr"><<a href="mailto:simon@atanasyan.com" target="_blank">simon@atanasyan.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: atanasyan<br>
Date: Mon Nov  4 13:40:02 2013<br>
New Revision: 194010<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=194010&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=194010&view=rev</a><br>
Log:<br>
[ELF] Fix typo in the expression calculates an absolute atom offset.<br>
<br>
Patch reviewed by Shankar Easwaran.<br>
<br>
Modified:<br>
    lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp<br>
<br>
Modified: lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp?rev=194010&r1=194009&r2=194010&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp?rev=194010&r1=194009&r2=194010&view=diff</a><br>


==============================================================================<br>
--- lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp (original)<br>
+++ lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp Mon Nov  4 13:40:02 2013<br>
@@ -633,7 +633,7 @@ private:<br>
                                      - _sharedLibraryAtoms._elementCount;<br>
       if ( abIndex < _absoluteAtoms._elementCount ) {<br>
         const uint8_t* p = _absoluteAtoms._arrayStart<br>
-                                  + slIndex * _absoluteAtoms._elementSize;<br>
+                                  + abIndex * _absoluteAtoms._elementSize;<br>
         this->_targetsTable[i] = reinterpret_cast<const AbsoluteAtom*>(p);<br>
         continue;<br>
       }<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br></div>