<div dir="ltr">This looks OK to me. The code is never executed but it shouldn't have a warning either.<div><br></div><div>What compiler spotted this?</div><div><br></div><div>Poke Sebastian or Christian to push it to 5 and master. I am not going to be able to do that today.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Jul 30, 2020 at 7:47 AM Aschref Ben-Thabet <<a href="mailto:aschref.ben-thabet@embedded-brains.de">aschref.ben-thabet@embedded-brains.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">From: Aschref Ben Thabet <<a href="mailto:aschref.ben-thabet@embedded-brains.de" target="_blank">aschref.ben-thabet@embedded-brains.de</a>><br>
<br>
---<br>
 testsuites/psxtests/psxhdrs/string/strncat.c | 2 +-<br>
 1 file changed, 1 insertion(+), 1 deletion(-)<br>
<br>
diff --git a/testsuites/psxtests/psxhdrs/string/strncat.c b/testsuites/psxtests/psxhdrs/string/strncat.c<br>
index 730a56cfa6..d872be3408 100644<br>
--- a/testsuites/psxtests/psxhdrs/string/strncat.c<br>
+++ b/testsuites/psxtests/psxhdrs/string/strncat.c<br>
@@ -45,7 +45,7 @@<br>
    char buffer[SIZE] = "computer";<br>
    char *result;<br>
<br>
-   result = strncat( buffer, " program", 3 );<br>
+   result = strncat( buffer, " program", sizeof( buffer ) - 1 );<br>
<br>
    return ( result != NULL );<br>
  }<br>
-- <br>
2.26.2<br>
<br>
_______________________________________________<br>
devel mailing list<br>
<a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/devel" rel="noreferrer" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a><br>
</blockquote></div>