+2015-09-17 Alan Modra <amodra@gmail.com>
+
+ PR 18867
+ * elflink.c (elf_link_adjust_relocs): Correct start of insertion
+ sort main loop.
+
2015-09-16 Alan Modra <amodra@gmail.com>
PR 18867
memcpy (base, onebuf, elt_size);
}
- for (p = base + elt_size; p < end; )
+ for (p = base + elt_size; (p += elt_size) < end; )
{
/* base to p is sorted, *p is next to insert. */
r_off = (*ext_r_off) (p);
memmove (loc, p, runlen);
memcpy (loc + runlen, buf, sortlen);
}
- p += runlen;
+ p += runlen - elt_size;
}
- else
- p += elt_size;
}
/* Hashes are no longer valid. */
free (reldata->hashes);