From: Ian Lance Taylor Date: Tue, 5 Feb 2013 01:11:01 +0000 (+0000) Subject: re PR bootstrap/56198 (Go profiledbootstrap error) X-Git-Tag: upstream/12.2.0~71427 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ea99f6314dfb7dafa574c27bbee9f4fdef235129;p=platform%2Fupstream%2Fgcc.git re PR bootstrap/56198 (Go profiledbootstrap error) PR bootstrap/56198 compiler: Always initialize *nested_off in interpret_header. From-SVN: r195747 --- diff --git a/gcc/go/gofrontend/import-archive.cc b/gcc/go/gofrontend/import-archive.cc index 032c6a0..9a1d5b3 100644 --- a/gcc/go/gofrontend/import-archive.cc +++ b/gcc/go/gofrontend/import-archive.cc @@ -277,6 +277,7 @@ Archive_file::interpret_header(const Archive_header* hdr, off_t off, return false; } + *nested_off = 0; if (hdr->ar_name[0] != '/') { const char* name_end = strchr(hdr->ar_name, '/'); @@ -288,7 +289,6 @@ Archive_file::interpret_header(const Archive_header* hdr, off_t off, return false; } pname->assign(hdr->ar_name, name_end - hdr->ar_name); - *nested_off = 0; } else if (hdr->ar_name[1] == ' ') { @@ -327,8 +327,7 @@ Archive_file::interpret_header(const Archive_header* hdr, off_t off, return false; } pname->assign(name, name_end - 1 - name); - if (nested_off != NULL) - *nested_off = y; + *nested_off = y; } return true;