------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-08-29 08:40 ------- Subject: Bug 23484
CVSROOT: /cvs/gcc Module name: gcc Changes by: [EMAIL PROTECTED] 2005-08-29 08:40:48 Modified files: gcc : ChangeLog builtins.c gcc/testsuite : ChangeLog Added files: gcc/testsuite/gcc.c-torture/execute/builtins: pr23484-chk-lib.c pr23484-chk.c Log message: PR middle-end/23484 * builtins.c (fold_builtin_memory_chk, fold_builtin_stxcpy_chk, fold_builtin_strncpy_chk, fold_builtin_snprintf_chk): If len is not constant, but maxlen is, don't set len to maxlen, rather set maxlen to len if len is a constant. * gcc.c-torture/execute/builtins/pr23484-chk.c: New test. * gcc.c-torture/execute/builtins/pr23484-chk-lib.c: New file. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.9847&r2=2.9848 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/builtins.c.diff?cvsroot=gcc&r1=1.474&r2=1.475 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.5974&r2=1.5975 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/builtins/pr23484-chk-lib.c.diff?cvsroot=gcc&r1=NONE&r2=1.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/builtins/pr23484-chk.c.diff?cvsroot=gcc&r1=NONE&r2=1.1 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23484