Commit 93051e0f by Kaveh R. Ghazi Committed by Kaveh Ghazi

builtins.c (expand_builtin_strncat): Remove redundant check for INTEGER_CST.

	* builtins.c (expand_builtin_strncat): Remove redundant check for
	INTEGER_CST.

From-SVN: r49246
parent 2198265a
2002-01-26 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* builtins.c (expand_builtin_strncat): Remove redundant check for
INTEGER_CST.
2002-01-25 David O'Brien <obrien@FreeBSD.org> 2002-01-25 David O'Brien <obrien@FreeBSD.org>
* config/i386/x86-64.h (DEFAULT_PCC_STRUCT_RETURN): Do not overide * config/i386/x86-64.h (DEFAULT_PCC_STRUCT_RETURN): Do not overide
......
...@@ -2608,8 +2608,7 @@ expand_builtin_strncat (arglist, target, mode) ...@@ -2608,8 +2608,7 @@ expand_builtin_strncat (arglist, target, mode)
/* If the requested length is zero, or the src parameter string /* If the requested length is zero, or the src parameter string
length is zero, return the dst parameter. */ length is zero, return the dst parameter. */
if ((TREE_CODE (len) == INTEGER_CST && integer_zerop (len)) if (integer_zerop (len) || (p && *p == '\0'))
|| (p && *p == '\0'))
{ {
/* Evaluate and ignore the src and len parameters in case /* Evaluate and ignore the src and len parameters in case
they have side-effects. */ they have side-effects. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment