[Bug middle-end/80669] [8 Regression] Bad -Wstringop-overflow warnings for stpncpy

msebor at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon May 8 15:50:00 GMT 2017


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80669

Martin Sebor <msebor at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |msebor at gcc dot gnu.org

--- Comment #2 from Martin Sebor <msebor at gcc dot gnu.org> ---
The bug is expand_builtin_stpncpy working too hard (and not entirely correctly)
to compute the size of the source sequence.  It should leave it to the
check_sizes function which already does this work and does it right, like
strncpy does.  Let me fix that today.


More information about the Gcc-bugs mailing list