Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2279)

Issue 4446047: [google] Avoid reading struct member from structure generated by different gcc version

Can't Edit
Can't Publish+Mail
Start Review
Created:
13 years, 2 months ago by martint
Modified:
13 years, 2 months ago
Reviewers:
richard.guenther, davidxl, Diego Novillo
CC:
gcc-patches_gcc.gnu.org
Base URL:
svn+ssh://gcc.gnu.org/svn/gcc/branches/google/main/
Visibility:
Public.

Description

This patch works around a segfault that can happen if we read in profiledata that is stored with an incompatible gcov_info structure. To be applied only to google/main branch. Tested by buildit --run-tests. Noticed unrelated error in libmudflap. 2011-04-17 Martin Thuresson <martint@google.com> * gcc/libgcov.c (gcov_version): Do not access filename in struct generated from different version.

Patch Set 1 #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -1 line) Patch
M gcc/libgcov.c View 1 chunk +1 line, -1 line 1 comment Download

Messages

Total messages: 4
martint
13 years, 2 months ago (2011-04-18 17:38:34 UTC) #1
davidxl
LGTM http://codereview.appspot.com/4446047/diff/1/gcc/libgcov.c File gcc/libgcov.c (right): http://codereview.appspot.com/4446047/diff/1/gcc/libgcov.c#newcode155 gcc/libgcov.c:155: filename? filename : "", e, v); Better split ...
13 years, 2 months ago (2011-04-18 19:59:13 UTC) #2
richard.guenther_gmail.com
On Mon, Apr 18, 2011 at 9:59 PM, <davidxl@google.com> wrote: > LGTM > > > ...
13 years, 2 months ago (2011-04-18 21:24:52 UTC) #3
Diego Novillo
13 years, 2 months ago (2011-04-18 23:43:39 UTC) #4
On Mon, Apr 18, 2011 at 17:24, Richard Guenther
<richard.guenther@gmail.com> wrote:
> On Mon, Apr 18, 2011 at 9:59 PM,  <davidxl@google.com> wrote:
>> LGTM
>>
>>
>> http://codereview.appspot.com/4446047/diff/1/gcc/libgcov.c
>> File gcc/libgcov.c (right):
>>
>> http://codereview.appspot.com/4446047/diff/1/gcc/libgcov.c#newcode155
>> gcc/libgcov.c:155: filename? filename : "", e, v);
>> Better split it into two different printfs as the format is different --
>> otherwise double : will be printed.
>>
>> http://codereview.appspot.com/4446047/
>
> I'm confused.  Can we please avoid this kind of mails?

It's not altogether easy.  I filed an enhancement request for
Rietveld, but I'm not sure how eager they will be to implement this.
http://code.google.com/p/rietveld/issues/detail?id=291&sort=-id

Two workarounds:

- Reply to the patch using the Reply button in the web interface.
- Reply using to the initial e-mail generated by Rietveld.
- Cut and paste context from the window when replying via the web interface.

Medium/long term, we could probably install our own Rietveld instance
in gcc.gnu.org and modify it to our taste.  Either that or look for
another patch review tool.

If anyone has any other suggestions, please let me know.



Diego.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b