public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "mark at infocomm dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug lto/51744] Erroneous warning: memset used with constant zero length parameter
Date: Mon, 24 Mar 2014 12:32:00 -0000	[thread overview]
Message-ID: <bug-51744-4-Z0NVhBwR87@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-51744-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51744

--- Comment #9 from Mark Pizzolato <mark at infocomm dot com> ---
> When val == 0 then the case of len == 0 is ambiguous and you can't really
tell the user they swapped val and len (because they are equal).

That is certainly true.

I'm not sure how that specifically relates to the problem since the warning
message is only about the length being 0.

The problem is that the warning is being issued incorrectly when the set value
is != 0 and the length is not a constant.


  parent reply	other threads:[~2014-03-24 12:32 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-03 20:05 [Bug lto/51744] New: " richardn26 at gmail dot com
2012-01-04 10:31 ` [Bug lto/51744] " rguenth at gcc dot gnu.org
2012-10-23 16:42 ` mark at infocomm dot com
2012-10-23 16:43 ` mark at infocomm dot com
2014-03-21  8:58 ` rguenth at gcc dot gnu.org
2014-03-21  9:00 ` rguenth at gcc dot gnu.org
2014-03-21  9:03 ` rguenth at gcc dot gnu.org
2014-03-24 11:22 ` rguenth at gcc dot gnu.org
2014-03-24 11:49 ` mark at infocomm dot com
2014-03-24 12:14 ` rguenth at gcc dot gnu.org
2014-03-24 12:32 ` mark at infocomm dot com [this message]
2014-03-24 13:55 ` rguenth at gcc dot gnu.org
2014-08-07  1:05 ` amodra at gmail dot com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-51744-4-Z0NVhBwR87@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).