]> Cypherpunks repositories - gostls13.git/commitdiff
ld: don't skip first 2 symbols in ldpe.
authorWei Guangjing <vcc.163@gmail.com>
Mon, 25 Jul 2011 16:25:44 +0000 (12:25 -0400)
committerRuss Cox <rsc@golang.org>
Mon, 25 Jul 2011 16:25:44 +0000 (12:25 -0400)
some object files don't has file name symbol.

R=golang-dev, lucio.dere, rsc
CC=golang-dev
https://golang.org/cl/4814051

src/cmd/ld/ldpe.c

index 049edeb23f65fef56f2434f76c6c17fc0007fcee..c2b34eee6b58927064cc1e266f55779890f21acf 100644 (file)
@@ -311,8 +311,7 @@ ldpe(Biobuf *f, char *pkg, int64 len, char *pn)
        }
        
        // enter sub-symbols into symbol table.
-       // frist 2 entry is file name.
-       for(i=2; i<obj->npesym; i++) {
+       for(i=0; i<obj->npesym; i++) {
                if(obj->pesym[i].name == 0)
                        continue;
                if(obj->pesym[i].name[0] == '.') //skip section