public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Martin Liska <marxin@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r13-504] opts-global.cc: document last change
Date: Mon, 16 May 2022 09:09:06 +0000 (GMT)	[thread overview]
Message-ID: <20220516090906.8D6B03857348@sourceware.org> (raw)

https://gcc.gnu.org/g:8ab53e65a60cc151ff9b5b48c749d40e0bd58756

commit r13-504-g8ab53e65a60cc151ff9b5b48c749d40e0bd58756
Author: Martin Liska <mliska@suse.cz>
Date:   Mon May 16 11:07:57 2022 +0200

    opts-global.cc: document last change
    
    gcc/ChangeLog:
    
            * opts-global.cc (write_langs): Add comment.

Diff:
---
 gcc/opts-global.cc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/gcc/opts-global.cc b/gcc/opts-global.cc
index 4f5f8cdcb98..4355e26747a 100644
--- a/gcc/opts-global.cc
+++ b/gcc/opts-global.cc
@@ -61,6 +61,8 @@ write_langs (unsigned int mask)
     if (mask & (1U << n))
       len += strlen (lang_name) + 1;
 
+  /* Allocate at least one character as we'll terminate the string
+     at the very end of this function.  */
   result = XNEWVEC (char, MAX (1, len));
   len = 0;
   for (n = 0; (lang_name = lang_names[n]) != 0; n++)


                 reply	other threads:[~2022-05-16  9:09 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20220516090906.8D6B03857348@sourceware.org \
    --to=marxin@gcc.gnu.org \
    --cc=gcc-cvs@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).