<div dir="ltr"><div>This implementation of strnlen reads one more byte than is allowed by the specification at <a href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/strlen.html">http://pubs.opengroup.org/onlinepubs/9699919799/functions/strlen.html</a>.<br><br></div>-- HT<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 24, 2016 at 2:06 PM, Chi-Hua Chen via llvm-commits <span dir="ltr"><<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Some older platforms, e.g. Mac 10.6.8, do not have strnlen. Define one<br>
in Support when necessary.<br>
<br>
Cc-ing dexonsmith because the commit below is the first one using strnlen<br>
---<br>
commit 839cd13b65d802f06276ff88d23441<wbr>9c38a44199<br>
Author: Duncan P. N. Exon Smith <<a href="mailto:dexonsmith@apple.com">dexonsmith@apple.com</a>><br>
Date:   Sun Feb 21 00:14:36 2016 +0000<br>
<br>
    Lex: Never overflow the file in HeaderMap::lookupFilename()<br>
---<br>
See <a href="https://llvm.org/bugs/show_bug.cgi?id=27714" rel="noreferrer" target="_blank">https://llvm.org/bugs/show_<wbr>bug.cgi?id=27714</a><br>
<span class="HOEnZb"><font color="#888888"><br>
- Chi-Hua Chen<br>
</font></span><br>
p.s. This is the first time I submit to llvm-commits. I've read the<br>
Developer Policy but please let me know if I am not doing it right<br>
<br>______________________________<wbr>_________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-commits</a><br>
<br></blockquote></div><br></div>