Commit 39b751ce by Richard Kenner

(check_format_info): Make test for null pointer more general.

From-SVN: r10479
parent 7bd7a756
......@@ -874,7 +874,7 @@ check_format_info (info, params)
/* We can only check the format if it's a string constant. */
while (TREE_CODE (format_tree) == NOP_EXPR)
format_tree = TREE_OPERAND (format_tree, 0); /* strip coercion */
if (format_tree == null_pointer_node)
if (integer_zerop (format_tree))
{
warning ("null format string");
return;
......
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