From: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
To: gcc-patches@gcc.gnu.org, fortran@gcc.gnu.org
Cc: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Subject: [PATCH 0/2] incpath, Fortran: Fix memory leak in gfc_add_include_path
Date: Fri, 5 Nov 2021 22:17:16 +0100 [thread overview]
Message-ID: <20211105211718.2261686-1-rep.dot.nop@gmail.com> (raw)
Hi!
In order to fix this very minor leak, we need a knob to free all
cpp_dirs that were added.
This adds a free_cpp_dirs() to gcc/incpath and needs review from some
global maintainer or maybe libcpp maintainer for this hunk.
Bootstrapped and regtested on x86_64-unknown-linux without regressions.
Ok for tunk?
Bernhard Reutner-Fischer (2):
Add free_cpp_dirs()
Fortran: Fix memory leak in gfc_add_include_path [PR68800]
gcc/fortran/cpp.c | 13 +++++++++++--
gcc/fortran/cpp.h | 1 +
gcc/fortran/f95-lang.c | 2 +-
gcc/fortran/scanner.c | 7 ++++---
gcc/incpath.c | 13 +++++++++++++
gcc/incpath.h | 1 +
6 files changed, 31 insertions(+), 6 deletions(-)
--
2.33.0
next reply other threads:[~2021-11-05 21:17 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-05 21:17 Bernhard Reutner-Fischer [this message]
2021-11-05 21:17 ` [PATCH 1/2] Add free_cpp_dirs() Bernhard Reutner-Fischer
2021-11-05 21:17 ` [PATCH 2/2] Fortran: Fix memory leak in gfc_add_include_path [PR68800] Bernhard Reutner-Fischer
2021-11-06 19:22 ` Harald Anlauf
2021-11-07 1:38 ` Bernhard Reutner-Fischer
2023-04-02 19:27 ` Bernhard Reutner-Fischer
2021-11-05 22:59 ` [PATCH 0/2] incpath, Fortran: Fix memory leak in gfc_add_include_path Bernhard Reutner-Fischer
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=20211105211718.2261686-1-rep.dot.nop@gmail.com \
--to=rep.dot.nop@gmail.com \
--cc=fortran@gcc.gnu.org \
--cc=gcc-patches@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).