aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/internal/obj/data.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd/internal/obj/data.go')
-rw-r--r--src/cmd/internal/obj/data.go8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/cmd/internal/obj/data.go b/src/cmd/internal/obj/data.go
index 438435fd58..f4562d9938 100644
--- a/src/cmd/internal/obj/data.go
+++ b/src/cmd/internal/obj/data.go
@@ -52,14 +52,12 @@ func Symgrow(ctxt *Link, s *LSym, lsiz int64) {
s.P = s.P[:siz]
}
-func savedata(ctxt *Link, s *LSym, p *Prog, file string) {
+func savedata(ctxt *Link, p *Prog) {
+ s := p.From.Sym
off := int32(p.From.Offset)
siz := int32(p.From3.Offset)
if off < 0 || siz < 0 || off >= 1<<30 || siz >= 100 {
- log.Fatalf("%s: mangled input file", file)
- }
- if ctxt.Enforce_data_order != 0 && off < int32(len(s.P)) {
- ctxt.Diag("data out of order (already have %d)\n%v", len(s.P), p)
+ log.Fatalf("savedata: bad off=%d siz=%d", off, siz)
}
if s.Type == SBSS || s.Type == STLSBSS {
ctxt.Diag("cannot supply data for BSS var")