mxk / go-sqlite

SQLite Library for Go
BSD 3-Clause "New" or "Revised" License
59 stars 20 forks source link

go test failed for 2 tests: TestTail and TestParams #9

Open tejorupan opened 9 years ago

tejorupan commented 9 years ago

When I run "go test" on this package it failed, with the following:

============================================ failure: 1 === RUN TestTail --- FAIL: TestTail (0.00s) sqlite3_test.go:703: 711: s.Tail is a pointer into sql ...... ============================================ failure: 2 $ go test -run Params runtime: garbage collector found invalid heap pointer *(0xc208067b50+0xd8)=0x1 s=nil fatal error: invalid heap pointer

runtime stack: runtime.throw(0x98ff83) /proj/go/src/runtime/panic.go:491 +0xad fp=0x7fffb32c3bf0 sp=0x7fffb32c3bc0 scanblock(0xc208067b50, 0x420, 0x6d16ac) /proj/go/src/runtime/mgc0.c:378 +0x551 fp=0x7fffb32c3d30 sp=0x7fffb32c3bf0 scanframe(0x7fffb32c3e38, 0x0, 0x501) /proj/go/src/runtime/mgc0.c:719 +0x164 fp=0x7fffb32c3da0 sp=0x7fffb32c3d30 runtime.gentraceback(0x4a8c50, 0xc2080671b0, 0x0, 0xc208000c60, 0x0, 0x0, 0x7fffffff, 0x7fffb32c3ee8, 0x0, 0x0, ...) /proj/go/src/runtime/traceback.go:311 +0x7a8 fp=0x7fffb32c3e90 sp=0x7fffb32c3da0 scanstack(0xc208000c60) /proj/go/src/runtime/mgc0.c:777 +0x21c fp=0x7fffb32c3f00 sp=0x7fffb32c3e90 markroot(0xc208010000, 0xa) /proj/go/src/runtime/mgc0.c:553 +0xe7 fp=0x7fffb32c3f60 sp=0x7fffb32c3f00 runtime.parfordo(0xc208010000) /proj/go/src/runtime/parfor.c:76 +0xb2 fp=0x7fffb32c3fe0 sp=0x7fffb32c3f60 gc(0x7fffb32c4118) /proj/go/src/runtime/mgc0.c:1439 +0x25e fp=0x7fffb32c40f8 sp=0x7fffb32c3fe0 runtime.gc_m() /proj/go/src/runtime/mgc0.c:1368 +0xe0 fp=0x7fffb32c4130 sp=0x7fffb32c40f8 runtime.onM(0x995f10) /proj/go/src/runtime/asm_amd64.s:257 +0x68 fp=0x7fffb32c4138 sp=0x7fffb32c4130 runtime.mstart() /proj/go/src/runtime/proc.c:786 fp=0x7fffb32c4140 sp=0x7fffb32c4138

goroutine 5 [garbage collection]: runtime.switchtoM() /proj/go/src/runtime/asm_amd64.s:198 fp=0xc2080671b8 sp=0xc2080671b0 runtime.gogc(0x0) /proj/go/src/runtime/malloc.go:469 +0x1cf fp=0xc2080671f0 sp=0xc2080671b8 runtime.mallocgc(0x120, 0x63f440, 0xc200000000, 0x10) /proj/go/src/runtime/malloc.go:341 +0x391 fp=0xc2080672a0 sp=0xc2080671f0 runtime.newarray(0x63f440, 0x1, 0x830430d1dfcb81a1) /proj/go/src/runtime/malloc.go:365 +0xc1 fp=0xc2080672d8 sp=0xc2080672a0 runtime.mapassign1(0x5eb440, 0xc20803af90, 0xc208067570, 0xc2080673c7) /proj/go/src/runtime/hashmap.go:395 +0x109 fp=0xc208067378 sp=0xc2080672d8 reflect.deepValueEqual(0x649fe0, 0xc20802efc0, 0xd9, 0x649fe0, 0xc20802ef80, 0xd9, 0xc20803af90, 0x1, 0xc208012001) /proj/go/src/reflect/deepequal.go:60 +0x418 fp=0xc208067598 sp=0xc208067378 reflect.deepValueEqual(0x5dd260, 0xc20802efc0, 0x16, 0x5dd260, 0xc20802ef80, 0x16, 0xc20803af90, 0x0, 0x0) /proj/go/src/reflect/deepequal.go:93 +0xe0b fp=0xc2080677b8 sp=0xc208067598 reflect.DeepEqual(0x5dd260, 0xc20802efc0, 0x5dd260, 0xc20802ef80, 0x4) /proj/go/src/reflect/deepequal.go:144 +0x1e2 fp=0xc208067858 sp=0xc2080677b8 github.com/mxk/go-sqlite/sqlite3_test.func·009(0x5ec740, 0xc208028d58, 0x5ec740, 0xc208028d60, 0x5ec740, 0xc208028d68, 0x5ec740, 0xc208028d70) /myproj/src/github.com/mxk/go-sqlite/sqlite3/sqlite3_test.go:750 +0x93b fp=0xc208067a60 sp=0xc208067858 github.com/mxk/go-sqlite/sqlite3_test.TestParams(0xc208070000) /myproj/src/github.com/mxk/go-sqlite/sqlite3/sqlite3_test.go:826 +0x464b fp=0xc208067f78 sp=0xc208067a60 testing.tRunner(0xc208070000, 0x97f6a8) /proj/go/src/testing/testing.go:447 +0xbf fp=0xc208067fd0 sp=0xc208067f78 runtime.goexit() /proj/go/src/runtime/asm_amd64.s:2232 +0x1 fp=0xc208067fd8 sp=0xc208067fd0 created by testing.RunTests /proj/go/src/testing/testing.go:555 +0xa8b