From: Andreas Schwab Date: Sat, 13 Oct 2012 18:41:08 +0000 (+0000) Subject: re PR gcov-profile/44728 (gcov chokes when "." is present in DIR argument to -o flag) X-Git-Tag: misc/gccgo-go1_1_2~186 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=258ef00780344ea3565b3276a60343529e94acc3;p=thirdparty%2Fgcc.git re PR gcov-profile/44728 (gcov chokes when "." is present in DIR argument to -o flag) PR gcov-profile/44728 * gcov.c (create_file_names): When stripping extension only look at base name. From-SVN: r192425 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 000b0d2cfea1..f961a99aa5ae 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2012-10-13 Andreas Schwab + + PR gcov-profile/44728 + * gcov.c (create_file_names): When stripping extension only look + at base name. + 2012-10-13 Jan Hubicka * loop-iv.c (determine_max_iter): Fix handling of AND. diff --git a/gcc/gcov.c b/gcc/gcov.c index cf26ce19a2c7..09831c2c6d6e 100644 --- a/gcc/gcov.c +++ b/gcc/gcov.c @@ -842,7 +842,7 @@ create_file_names (const char *file_name) } /* Remove the extension. */ - cptr = strrchr (name, '.'); + cptr = strrchr (CONST_CAST (char *, lbasename (name)), '.'); if (cptr) *cptr = 0;