From: Florian Krohm Date: Tue, 16 Dec 2014 12:04:03 +0000 (+0000) Subject: Add a clarifying comment. X-Git-Tag: svn/VALGRIND_3_11_0~773 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=71443eff491f57c39d6c23398b309a5a5f823ad9;p=thirdparty%2Fvalgrind.git Add a clarifying comment. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14813 --- diff --git a/coregrind/m_redir.c b/coregrind/m_redir.c index a4738e2427..5075b061d2 100644 --- a/coregrind/m_redir.c +++ b/coregrind/m_redir.c @@ -1181,6 +1181,10 @@ static void add_hardwired_spec (const HChar* sopatt, const HChar* fnpatt, vg_assert(topSpecs->next == NULL); vg_assert(topSpecs->seginfo == NULL); /* FIXED PARTS */ + /* Note, that these CONST_CAST will not cause a problem, in the sense + that VG_(redir_notify_delete_DebugInfo) will delete them. The reason + is that the TopSpec here has seginfo == NULL and such a TopSpec will + never be freed. See the asserts at the beginning of said function. */ spec->from_sopatt = CONST_CAST(HChar *,sopatt); spec->from_fnpatt = CONST_CAST(HChar *,fnpatt); spec->to_addr = to_addr;