{"action":"closed","issue":{"url":"https://api.github.com/repos/golang/go/issues/12158","labels_url":"https://api.github.com/repos/golang/go/issues/12158/labels{/name}","comments_url":"https://api.github.com/repos/golang/go/issues/12158/comments","events_url":"https://api.github.com/repos/golang/go/issues/12158/events","html_url":"https://github.com/golang/go/issues/12158","id":101218719,"number":12158,"title":"runtime: invalidptr check triggered on darwin/amd64 with cgo","user":{"login":"rsc","id":104030,"avatar_url":"https://avatars.githubusercontent.com/u/104030?v=3","gravatar_id":"","url":"https://api.github.com/users/rsc","html_url":"https://github.com/rsc","followers_url":"https://api.github.com/users/rsc/followers","following_url":"https://api.github.com/users/rsc/following{/other_user}","gists_url":"https://api.github.com/users/rsc/gists{/gist_id}","starred_url":"https://api.github.com/users/rsc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rsc/subscriptions","organizations_url":"https://api.github.com/users/rsc/orgs","repos_url":"https://api.github.com/users/rsc/repos","events_url":"https://api.github.com/users/rsc/events{/privacy}","received_events_url":"https://api.github.com/users/rsc/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/golang/go/milestones/2","html_url":"https://github.com/golang/go/milestones/Go1.5Maybe","labels_url":"https://api.github.com/repos/golang/go/milestones/2/labels","id":905114,"number":2,"title":"Go1.5Maybe","description":"Things that might make Go 1.5, but aren't critical.\r\n","creator":{"login":"bradfitz","id":2621,"avatar_url":"https://avatars.githubusercontent.com/u/2621?v=3","gravatar_id":"","url":"https://api.github.com/users/bradfitz","html_url":"https://github.com/bradfitz","followers_url":"https://api.github.com/users/bradfitz/followers","following_url":"https://api.github.com/users/bradfitz/following{/other_user}","gists_url":"https://api.github.com/users/bradfitz/gists{/gist_id}","starred_url":"https://api.github.com/users/bradfitz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bradfitz/subscriptions","organizations_url":"https://api.github.com/users/bradfitz/orgs","repos_url":"https://api.github.com/users/bradfitz/repos","events_url":"https://api.github.com/users/bradfitz/events{/privacy}","received_events_url":"https://api.github.com/users/bradfitz/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":45,"state":"open","created_at":"2014-12-16T02:39:13Z","updated_at":"2015-08-16T19:07:59Z","due_on":"2015-07-31T04:00:00Z","closed_at":null},"comments":2,"created_at":"2015-08-15T23:14:14Z","updated_at":"2015-08-16T19:07:59Z","closed_at":"2015-08-16T19:07:59Z","body":"Split from issue #12138 to separate amd64 report (this one) from arm report (now #12157).\n\n#### Comment by @jtsylve (2015-08-13 23:53:57)\n\nI'm seeing the same thing on Go 1.5rc1 on Darwin x86_64 with no such error on Go 1.4.2\r\n\r\n```\r\nruntime:objectstart Span weird: p=0xc830fca000 k=0x64187e5 s.start=0xc830fca000 s.limit=0x0 s.state=2\r\nfatal error: objectstart: bad pointer in unexpected span\r\n\r\nruntime stack:\r\nruntime.throw(0x42a56a0, 0x2b)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/panic.go:527 +0x90\r\nruntime.heapBitsForObject(0xc830fca000, 0x0, 0x0, 0xc800000000, 0x923c2c0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mbitmap.go:214 +0x28c\r\nruntime.scanobject(0xc823282d20, 0xc82001e720)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:863 +0x232\r\nruntime.gcDrainN(0xc82001e720, 0x1bee3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:764 +0x8e\r\nruntime.gcAssistAlloc.func1()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:232 +0x172\r\nruntime.systemstack(0xc82001d500)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:262 +0x79\r\nruntime.mstart()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:674\r\n\r\ngoroutine 76 [running]:\r\nruntime.systemstack_switch()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:216 fp=0xc82475b378 sp=0xc82475b370\r\nruntime.gcAssistAlloc(0x12000, 0xc82048ca01)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:272 +0x1f8 fp=0xc82475b3d8 sp=0xc82475b378\r\nruntime.mallocgc(0x12000, 0x41e8fe0, 0x1, 0x8000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:711 +0x535 fp=0xc82475b4a8 sp=0xc82475b3d8\r\nruntime.newarray(0x41e8fe0, 0x10200, 0xc82475b548)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:777 +0xc9 fp=0xc82475b4e8 sp=0xc82475b4a8\r\nruntime.makeslice(0x41e0400, 0x10200, 0x10200, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/slice.go:32 +0x165 fp=0xc82475b538 sp=0xc82475b4e8\r\nbytes.makeSlice(0x10200, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:195 +0x64 fp=0xc82475b588 sp=0xc82475b538\r\nbytes.(*Buffer).ReadFrom(0xc82d77bd50, 0x5148928, 0xc825320bc0, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:167 +0xd3 fp=0xc82475b638 sp=0xc82475b588\r\nio.copyBuffer(0x5148690, 0xc82d77bd50, 0x5148928, 0xc825320bc0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc82475b6f8 sp=0xc82475b638\r\nio.Copy(0x5148690, 0xc82d77bd50, 0x5148928, 0xc825320bc0, 0xc8204a2900, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc82475b750 sp=0xc82475b6f8\r\nio.CopyN(0x5148690, 0xc82d77bd50, 0x47a42b0, 0xc82268a020, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc82475b7d0 sp=0xc82475b750\r\ngo4n6/compress/zlib.(*reader).Read(0xc823282dc0, 0xc82dd06000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:75 +0x198 fp=0xc82475b8e8 sp=0xc82475b7d0\r\nio.(*LimitedReader).Read(0xc825320ba0, 0xc82dd06000, 0x8000, 0x8000, 0x407cc90, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc82475b938 sp=0xc82475b8e8\r\nbytes.(*Buffer).ReadFrom(0xc82d77bce0, 0x5148928, 0xc825320ba0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc82475b9e8 sp=0xc82475b938\r\nio.copyBuffer(0x5148690, 0xc82d77bce0, 0x5148928, 0xc825320ba0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc82475baa8 sp=0xc82475b9e8\r\nio.Copy(0x5148690, 0xc82d77bce0, 0x5148928, 0xc825320ba0, 0xc8204a2900, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc82475bb00 sp=0xc82475baa8\r\nio.CopyN(0x5148690, 0xc82d77bce0, 0x5148828, 0xc823282dc0, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc82475bb80 sp=0xc82475bb00\r\ngo4n6/disk/ewf.decompress(0x51487c8, 0xc82268a020, 0x18eef, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc82475be80 sp=0xc82475bb80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821df8d50, 0xc820806000, 0x1)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc82475bf88 sp=0xc82475be80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82475bf90 sp=0xc82475bf88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\n...\r\n```\n\n\n#### Comment by @jtsylve (2015-08-13 23:59:55)\n\nFull stack trace (Not sure it'll help without the source)\r\n\r\n```\r\nruntime:objectstart Span weird: p=0xc827f70000 k=0x6413fb8 s.start=0xc827f70000 s.limit=0x0 s.state=2\r\nfatal error: objectstart: bad pointer in unexpected span\r\n\r\nruntime stack:\r\nruntime.throw(0x42a56a0, 0x2b)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/panic.go:527 +0x90\r\nruntime.heapBitsForObject(0xc827f70000, 0x0, 0x0, 0xc800000000, 0x9405180)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mbitmap.go:214 +0x28c\r\nruntime.scanobject(0xc82b341720, 0xc820026720)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:863 +0x232\r\nruntime.gcDrainN(0xc820026720, 0x8bc7)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:764 +0x8e\r\nruntime.gcAssistAlloc.func1()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:232 +0x172\r\nruntime.systemstack(0xc82001ea00)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:262 +0x79\r\nruntime.mstart()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:674\r\n\r\ngoroutine 75 [running]:\r\nruntime.systemstack_switch()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:216 fp=0xc827dd9610 sp=0xc827dd9608\r\nruntime.gcAssistAlloc(0x8000, 0x407cc01)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:272 +0x1f8 fp=0xc827dd9670 sp=0xc827dd9610\r\nruntime.mallocgc(0x8000, 0x41e8fe0, 0x1, 0xc820032900)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:711 +0x535 fp=0xc827dd9740 sp=0xc827dd9670\r\nruntime.newarray(0x41e8fe0, 0x8000, 0xc827dd97d0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:777 +0xc9 fp=0xc827dd9780 sp=0xc827dd9740\r\nruntime.makeslice(0x41e0400, 0x0, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/slice.go:32 +0x165 fp=0xc827dd97d0 sp=0xc827dd9780\r\ngo4n6/compress/zlib.(*reader).Read(0xc824739b80, 0xc827fd6000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:73 +0xab fp=0xc827dd98e8 sp=0xc827dd97d0\r\nio.(*LimitedReader).Read(0xc821dd9680, 0xc827fd6000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc827dd9938 sp=0xc827dd98e8\r\nbytes.(*Buffer).ReadFrom(0xc82490ec40, 0x47b4da0, 0xc821dd9680, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc827dd99e8 sp=0xc827dd9938\r\nio.copyBuffer(0x47b4bb8, 0xc82490ec40, 0x47b4da0, 0xc821dd9680, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc827dd9aa8 sp=0xc827dd99e8\r\nio.Copy(0x47b4bb8, 0xc82490ec40, 0x47b4da0, 0xc821dd9680, 0xc82047a000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc827dd9b00 sp=0xc827dd9aa8\r\nio.CopyN(0x47b4bb8, 0xc82490ec40, 0x47b4d50, 0xc824739b80, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc827dd9b80 sp=0xc827dd9b00\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc8219be060, 0x18a75, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc827dd9e80 sp=0xc827dd9b80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc827dd9f88 sp=0xc827dd9e80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc827dd9f90 sp=0xc827dd9f88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 1 [chan receive]:\r\ngo4n6/file/mft.(*MFT).Decode(0xc8227065a0, 0x51d42f8, 0xc822706570, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:224 +0x166\r\ngo4n6/fs/ntfs.(*NTFS).Entries(0xc821deaea0, 0xc822706101, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/fs/ntfs/ntfs.go:130 +0x97\r\nmain.main()\r\n\t/Users/joe/src/ntfstest.go:43 +0x990\r\n\r\ngoroutine 17 [syscall, locked to thread]:\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1\r\n\r\ngoroutine 101 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 99 [runnable]:\r\ngo4n6/ioutil.(*LookaheadReader).Get(0xc8207e6000, 0x18a6b, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:161 +0x443\r\ngo4n6/disk/ewf.(*segment).Read(0xc820094000, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:114 +0x1ea\r\ngo4n6/ioutil.(*MultiReadSeeker).Read(0xc820014900, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0xc5358000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/multi.go:90 +0x204\r\ngo4n6/disk/ewf.(*Reader).Read(0xc820012410, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:6 +0x82\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc822706180, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120\r\ngo4n6/partition/mbr.Partition.Read(0x5380100, 0xc822706180, 0xc8200866c0, 0xfffffe0700212080, 0x27ff00000000800, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0xc5258000, 0x0, ...)\r\n\t/Users/joe/go/src/go4n6/partition/mbr/partition.go:388 +0x6d\r\ngo4n6/partition/mbr.(*Partition).Read(0xc8227061b0, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:4 +0xc8\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc8227064e0, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120\r\ngithub.com/badgerodon/ioutil.(*MultiReadSeeker).Read(0xc822706540, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/multi.go:39 +0x204\r\ngo4n6/ioutil.(*MultiRangeReadSeeker).Read(0xc822706570, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x8000, 0x0, 0x0)\r\n\t<autogenerated>:24 +0x82\r\nio.(*LimitedReader).Read(0xc821c727e0, 0xc82ac7f000, 0x5bb000, 0x5bb000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc826ce58f0, 0x47b4da0, 0xc821c727e0, 0x445000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc826ce58f0, 0x47b4da0, 0xc821c727e0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc826ce58f0, 0x47b4da0, 0xc821c727e0, 0x4600e28, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc826ce58f0, 0x51d42f8, 0xc822706570, 0xa00000, 0xa00000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/file/mft.(*MFT).decodeEntries(0xc8227065a0, 0x51d42f8, 0xc822706570, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:92 +0x22f\r\ncreated by go4n6/file/mft.(*MFT).Decode\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:221 +0x123\r\n\r\ngoroutine 74 [semacquire]:\r\nsync.runtime_Semacquire(0xc821decc0c)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/sema.go:43 +0x26\r\nsync.(*WaitGroup).Wait(0xc821decc00)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/sync/waitgroup.go:126 +0xb4\r\ngo4n6/ioutil.(*LookaheadReader).start(0xc8207e6000)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:337 +0xbc\r\ncreated by go4n6/ioutil.(*LookaheadReader).Get\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:140 +0x1ec\r\n\r\ngoroutine 77 [runnable, locked to thread]:\r\ngo4n6/compress/zlib._Cfunc_inflate(0xc82b3417e8, 0xc800000000, 0x1)\r\n\t??:0 +0x39\r\ngo4n6/compress/zlib.(*reader).Read(0xc82b3417c0, 0xc82636c000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:99 +0x3d4\r\nio.(*LimitedReader).Read(0xc825023cc0, 0xc82636c000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc824b64e70, 0x47b4da0, 0xc825023cc0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc824b64e70, 0x47b4da0, 0xc825023cc0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc824b64e70, 0x47b4da0, 0xc825023cc0, 0xc82048e900, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc824b64e70, 0x47b4d50, 0xc82b3417c0, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc8219bc120, 0x18a79, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x2)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 76 [runnable]:\r\nbytes.makeSlice.func1()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:190\r\nbytes.makeSlice(0x10200, 0xc824076000, 0x10200, 0x10200)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:195 +0x92\r\nbytes.(*Buffer).ReadFrom(0xc824598460, 0x47b4da0, 0xc821c73240, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:167 +0xd3\r\nio.copyBuffer(0x47b4bb8, 0xc824598460, 0x47b4da0, 0xc821c73240, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc824598460, 0x47b4da0, 0xc821c73240, 0xc820032900, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc824598460, 0x47a42b0, 0xc822686020, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/compress/zlib.(*reader).Read(0xc82487f220, 0xc827d9c000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:75 +0x198\r\nio.(*LimitedReader).Read(0xc825023c40, 0xc827d9c000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc824b64cb0, 0x47b4da0, 0xc825023c40, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc824b64cb0, 0x47b4da0, 0xc825023c40, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc824b64cb0, 0x47b4da0, 0xc825023c40, 0xc82048e900, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc824b64cb0, 0x47b4d50, 0xc82487f220, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc822686020, 0x18a74, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x1)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 80 [runnable]:\r\ngo4n6/compress/zlib.(*reader).Read(0xc82b341540, 0xc828f26000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:73 +0xe2\r\nio.(*LimitedReader).Read(0xc825023b40, 0xc828f26000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc824b64af0, 0x47b4da0, 0xc825023b40, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc824b64af0, 0x47b4da0, 0xc825023b40, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc824b64af0, 0x47b4da0, 0xc825023b40, 0xc82047a000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc824b64af0, 0x47b4d50, 0xc82b341540, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc822690020, 0x18a6d, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x5)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 79 [runnable]:\r\ngo4n6/compress/zlib.(*reader).Read(0xc824e86320, 0xc827ff8000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:73 +0xe2\r\nio.(*LimitedReader).Read(0xc8219bf960, 0xc827ff8000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc821a0c310, 0x47b4da0, 0xc8219bf960, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc821a0c310, 0x47b4da0, 0xc8219bf960, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc821a0c310, 0x47b4da0, 0xc8219bf960, 0xc82048e000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc821a0c310, 0x47b4d50, 0xc824e86320, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc82257d940, 0x18a76, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x4)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 78 [runnable]:\r\ngo4n6/compress/zlib.(*reader).Read(0xc824e86280, 0xc823ca4000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:73 +0xe2\r\nio.(*LimitedReader).Read(0xc8219bf900, 0xc823ca4000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc821a0c230, 0x47b4da0, 0xc8219bf900, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47b4bb8, 0xc821a0c230, 0x47b4da0, 0xc8219bf900, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47b4bb8, 0xc821a0c230, 0x47b4da0, 0xc8219bf900, 0xc82048e000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47b4bb8, 0xc821a0c230, 0x47b4d50, 0xc824e86280, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc821d96160, 0x18a6b, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x3)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 81 [runnable]:\r\ngo4n6/disk/ewf.decompress(0x47b4cf0, 0xc821deadc0, 0x18a77, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x34b\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc821decc00, 0xc8207e6000, 0x6)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 104 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 103 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 102 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 105 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 100 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 106 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 107 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc8205b8050, 0xc82001a120, 0xc8227065a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\nexit status 2\r\n```\n\n\n#### Comment by @jtsylve (2015-08-14 00:03:31)\n\nThis also panics on HEAD, so the bug hasn't been fixed since rc1.\n\n\n#### Comment by @aclements (2015-08-14 15:03:24)\n\n@jtsylve, it looks like your problem is probably different, since it doesn't involve finalizers or dead spans, though it might be the same. The check that's failing is quite general.\r\n\r\nCan you run and reproduce the problem with GODEBUG=gccheckmark=1? Also, it sounds like you can reproduce it fairly quickly. If that's right, I'd also like to know whether it happens with GODEBUG=gcstoptheworld=1,gcshrinkstackoff=1 and, if that stops it from happening, what happens with GODEBUG=gcstackbarrieroff=1.\r\n\r\nAlso, is there use of \"unsafe\" in your code? And is it possible to share the code or reduce it to a shareable test case?\n\n\n#### Comment by @jtsylve (2015-08-14 15:39:43)\n\nUnfortunately I can't share the majority of the code and it's now a rather complicated codebase, so I'm not sure if I can reduce it to a POC to create the panic, but I'll see what I can do.\r\n\r\nBingo on the \"unsafe\" call.  I'm using a custom `Reader` that uses zlib as a drop in replacement for `compress/zlib` (Because of performance).  I get no such panic on `compress/zlib` I can at least share that code. (Although this did work fine on 1.4.2)\r\n\r\n```go\r\n// #cgo LDFLAGS: -lz\r\n// #include <zlib.h>\r\n//\r\n// // inflateInit is a macro so we need to do this\r\n// int InflateInit(z_streamp s) {\r\n//     return inflateInit(s);\r\n// }\r\nimport \"C\"\r\n\r\nimport (\r\n\t\"bytes\"\r\n\t\"errors\"\r\n\t\"io\"\r\n\t\"unsafe\"\r\n)\r\n\r\ntype reader struct {\r\n\tr     io.Reader\r\n\tinbuf []byte\r\n\ts     C.z_stream\r\n}\r\n\r\n// NewReader creates a new ReadCloser. Reads from the returned ReadCloser\r\n// read and decompress data from r. The implementation buffers input and\r\n// may read more data than necessary from r. It is the caller's\r\n// responsibility to call Close on the ReadCloser when done.\r\nfunc NewReader(r io.Reader) (io.ReadCloser, error) {\r\n\trd := &reader{\r\n\t\tr: r,\r\n\t}\r\n\r\n\terr := C.InflateInit(&rd.s)\r\n\tif err != C.Z_OK {\r\n\t\treturn nil, errors.New(\"Could not init inflate.\")\r\n\t}\r\n\r\n\treturn rd, nil\r\n}\r\n\r\nfunc (r *reader) Read(p []byte) (n int, err error) {\r\n\tif len(p) == 0 {\r\n\t\treturn 0, nil\r\n\t}\r\n\r\n\t// We can assume that the input will be smaller than\r\n\t// output.\r\n\tmaxIn := int64(len(p))\r\n\r\n\tif r.inbuf == nil {\r\n\t\tbuf := bytes.NewBuffer(make([]byte, 0, maxIn))\r\n\r\n\t\tnIn, err := io.CopyN(buf, r.r, maxIn)\r\n\t\tif err != nil && err != io.EOF {\r\n\t\t\treturn 0, err\r\n\t\t}\r\n\r\n\t\tif nIn == 0 && err == io.EOF {\r\n\t\t\treturn 0, io.ErrUnexpectedEOF\r\n\t\t}\r\n\r\n\t\tr.s.avail_in = C.uInt(nIn)\r\n\t\tr.s.next_in = (*C.Bytef)(unsafe.Pointer(&buf.Bytes()[0]))\r\n\t} else {\r\n\t\t// We still have input from the last call\r\n\t\tr.s.avail_in = C.uInt(len(r.inbuf))\r\n\t\tr.s.next_in = (*C.Bytef)(unsafe.Pointer(&r.inbuf[0]))\r\n\t}\r\n\r\n\tvar read int\r\n\tvar ret C.int\r\n\tfor ret != C.Z_STREAM_END {\r\n\t\tout := p[read:]\r\n\t\tr.s.avail_out = C.uInt(len(out))\r\n\t\tr.s.next_out = (*C.Bytef)(unsafe.Pointer(&out[0]))\r\n\r\n\t\tret = C.inflate(&r.s, C.Z_NO_FLUSH)\r\n\r\n\t\tif ret != C.Z_STREAM_END && ret != C.Z_OK {\r\n\t\t\treturn 0, errors.New(\"Could not deflate input.\")\r\n\t\t}\r\n\r\n\t\tread = len(out) - int(r.s.avail_out)\r\n\r\n\t\tif r.s.avail_out == 0 {\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\r\n\tif ret == C.Z_STREAM_END {\r\n\t\treturn read, io.EOF\r\n\t}\r\n\r\n\tif r.s.avail_in == 0 {\r\n\t\tr.inbuf = nil\r\n\t} else {\r\n\t\tr.inbuf = C.GoBytes(unsafe.Pointer(r.s.next_in), C.int(r.s.avail_in))\r\n\t}\r\n\r\n\treturn read, nil\r\n}\r\n\r\n// Close implements the io.Closer interface\r\n//\r\n// Calling Close does not close the wrapped io.Reader originally passed to NewReader\r\nfunc (r *reader) Close() error {\r\n\terr := C.inflateEnd(&r.s)\r\n\tif err != C.Z_OK {\r\n\t\treturn errors.New(\"Could not end inflate\")\r\n\t}\r\n\r\n\treturn nil\r\n}\r\n```\r\n\r\nI'm not seeing much different in the outputs of setting those variables, but here they are.  Perhaps I'm doing it wrong?\r\n\r\n`GODEBUG=gccheckmark=1 go run ntfstest.go`\r\n```\r\nruntime:objectstart Span weird: p=0xc827a54000 k=0x6413d2a s.start=0xc827a54000 s.limit=0xc825cf5f80 s.state=2\r\nfatal error: objectstart: bad pointer in unexpected span\r\n\r\ngoroutine 10 [running]:\r\nruntime.throw(0x42a56a0, 0x2b)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/panic.go:527 +0x90 fp=0xc820028610 sp=0xc8200285f8\r\nruntime.heapBitsForObject(0xc827a54000, 0x0, 0x0, 0xc800000000, 0x50a40e0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mbitmap.go:214 +0x28c fp=0xc820028648 sp=0xc820028610\r\nruntime.scanobject(0xc82588a6e0, 0xc820022720)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:863 +0x232 fp=0xc820028718 sp=0xc820028648\r\nruntime.gcDrainUntilPreempt(0xc820022720, 0x7d0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:726 +0x152 fp=0xc820028750 sp=0xc820028718\r\nruntime.gcBgMarkWorker(0xc820021500)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:1328 +0x474 fp=0xc8200287b8 sp=0xc820028750\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8200287c0 sp=0xc8200287b8\r\ncreated by runtime.gcBgMarkStartWorkers\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:1238 +0x93\r\n\r\ngoroutine 1 [chan receive]:\r\ngo4n6/file/mft.(*MFT).Decode(0xc820d683c0, 0x50047c8, 0xc820d68390, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:224 +0x166\r\ngo4n6/fs/ntfs.(*NTFS).Entries(0xc82223e280, 0xc8223c0101, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/fs/ntfs/ntfs.go:130 +0x97\r\nmain.main()\r\n\t/Users/joe/src/ntfstest.go:43 +0x990\r\n\r\ngoroutine 17 [syscall, locked to thread]:\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1\r\n\r\ngoroutine 100 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 99 [runnable]:\r\ngo4n6/ioutil.(*LookaheadReader).Get(0xc82039e000, 0x18dca, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:161 +0x443\r\ngo4n6/disk/ewf.(*segment).Read(0xc820094000, 0xc82afa1000, 0x145000, 0x145000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:114 +0x1ea\r\ngo4n6/ioutil.(*MultiReadSeeker).Read(0xc820d3e120, 0xc82afa1000, 0x145000, 0x145000, 0xc6e50000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/multi.go:90 +0x204\r\ngo4n6/disk/ewf.(*Reader).Read(0xc8200123c0, 0xc82afa1000, 0x145000, 0x145000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:6 +0x82\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc8223c0120, 0xc82afa1000, 0x145000, 0x145000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120\r\ngo4n6/partition/mbr.Partition.Read(0x5249700, 0xc8223c0120, 0xc820086240, 0xfffffe0700212080, 0x27ff00000000800, 0xc82afa1000, 0x145000, 0x145000, 0xc6d50000, 0x0, ...)\r\n\t/Users/joe/go/src/go4n6/partition/mbr/partition.go:388 +0x6d\r\ngo4n6/partition/mbr.(*Partition).Read(0xc8223c0150, 0xc82afa1000, 0x145000, 0x145000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:4 +0xc8\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc820d68330, 0xc82afa1000, 0x145000, 0x145000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120\r\ngithub.com/badgerodon/ioutil.(*MultiReadSeeker).Read(0xc820d68360, 0xc82afa1000, 0x145000, 0x145000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/multi.go:39 +0x204\r\ngo4n6/ioutil.(*MultiRangeReadSeeker).Read(0xc820d68390, 0xc82afa1000, 0x145000, 0x145000, 0x8000, 0x0, 0x0)\r\n\t<autogenerated>:24 +0x82\r\nio.(*LimitedReader).Read(0xc822ddc880, 0xc82afa1000, 0x145000, 0x145000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc8251db2d0, 0x47ad130, 0xc822ddc880, 0x8bb000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47ad108, 0xc8251db2d0, 0x47ad130, 0xc822ddc880, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47ad108, 0xc8251db2d0, 0x47ad130, 0xc822ddc880, 0x4600000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47ad108, 0xc8251db2d0, 0x50047c8, 0xc820d68390, 0xa00000, 0xa00000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/file/mft.(*MFT).decodeEntries(0xc820d683c0, 0x50047c8, 0xc820d68390, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:92 +0x22f\r\ncreated by go4n6/file/mft.(*MFT).Decode\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:221 +0x123\r\n\r\ngoroutine 90 [semacquire]:\r\nsync.runtime_Semacquire(0xc82000b93c)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/sema.go:43 +0x26\r\nsync.(*WaitGroup).Wait(0xc82000b930)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/sync/waitgroup.go:126 +0xb4\r\ngo4n6/ioutil.(*LookaheadReader).start(0xc82039e000)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:337 +0xbc\r\ncreated by go4n6/ioutil.(*LookaheadReader).Get\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:140 +0x1ec\r\n\r\ngoroutine 92 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:53 +0x37\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:53 +0x37\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc8222b2020, 0x18dcd, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x1)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 95 [runnable]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:48\r\nbytes.makeSlice(0x10200, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:195 +0x64\r\nbytes.(*Buffer).ReadFrom(0xc82273f420, 0x47ad130, 0xc821be8180, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:167 +0xd3\r\nio.copyBuffer(0x47ad108, 0xc82273f420, 0x47ad130, 0xc821be8180, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47ad108, 0xc82273f420, 0x47ad130, 0xc821be8180, 0xc820509680, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47ad108, 0xc82273f420, 0x47a42b0, 0xc822244060, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/compress/zlib.(*reader).Read(0xc82588a780, 0xc82328c000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:75 +0x198\r\nio.(*LimitedReader).Read(0xc821be8160, 0xc82328c000, 0x8000, 0x8000, 0x407cca0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd\r\nbytes.(*Buffer).ReadFrom(0xc82273f3b0, 0x47ad130, 0xc821be8160, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f\r\nio.copyBuffer(0x47ad108, 0xc82273f3b0, 0x47ad130, 0xc821be8160, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180\r\nio.Copy(0x47ad108, 0xc82273f3b0, 0x47ad130, 0xc821be8160, 0xc820509680, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64\r\nio.CopyN(0x47ad108, 0xc82273f3b0, 0x47ad0b8, 0xc82588a780, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc822244060, 0x18ddd, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x4)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 96 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc82223e0e0, 0x18dcc, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x5)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 91 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:53 +0x37\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc822240060, 0x18dca, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 93 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc822258060, 0x18dcf, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x2)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 94 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:53 +0x37\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc8222a6020, 0x18dcb, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x3)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 97 [sleep]:\r\ntime.Sleep(0x186a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/time.go:59 +0xf9\r\ngo4n6/disk/ewf.decompress(0x47ad058, 0xc82222e8e0, 0x18dce, 0x4255fe0, 0xc820094000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc82000b930, 0xc82039e000, 0x6)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 105 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 104 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 103 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 102 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 106 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 101 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 107 [chan receive]:\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82254c960, 0xc82001a120, 0xc820d683c0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\nexit status 2\r\n```\r\n\r\n`GODEBUG=gcstoptheworld=1,gcshrinkstackoff=1 go run ntfstest.go`\r\n```\r\nruntime:objectstart Span weird: p=0xc8240ce000 k=0x6412067 s.start=0xc8240ce000 s.limit=0xc8240de200 s.state=2\r\nfatal error: objectstart: bad pointer in unexpected span\r\n\r\nruntime stack:\r\nruntime.throw(0x42a56a0, 0x2b)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/panic.go:527 +0x90 fp=0x7fff5fbff6c0 sp=0x7fff5fbff6a8\r\nruntime.heapBitsForObject(0xc8240ce000, 0x0, 0x0, 0xc800000000, 0x51454e0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mbitmap.go:214 +0x28c fp=0x7fff5fbff6f8 sp=0x7fff5fbff6c0\r\nruntime.scanobject(0xc821ce6320, 0x7fff5fbff818)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:863 +0x232 fp=0x7fff5fbff7c8 sp=0x7fff5fbff6f8\r\nruntime.gcDrain(0x7fff5fbff818, 0xffffffffffffffff)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcmark.go:674 +0xf4 fp=0x7fff5fbff7f8 sp=0x7fff5fbff7c8\r\nruntime.gchelper()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:1703 +0x89 fp=0x7fff5fbff840 sp=0x7fff5fbff7f8\r\nruntime.stopm()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:1131 +0x146 fp=0x7fff5fbff868 sp=0x7fff5fbff840\r\nruntime.gcstopm()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:1321 +0xf8 fp=0x7fff5fbff898 sp=0x7fff5fbff868\r\nruntime.schedule()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:1580 +0x9c fp=0x7fff5fbff8d0 sp=0x7fff5fbff898\r\nruntime.goschedImpl(0xc8200ae480)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:1697 +0x12a fp=0x7fff5fbff8e8 sp=0x7fff5fbff8d0\r\nruntime.gopreempt_m(0xc8200ae480)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc1.go:1712 +0x32 fp=0x7fff5fbff8f8 sp=0x7fff5fbff8e8\r\nruntime.newstack()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/stack1.go:786 +0xa92 fp=0x7fff5fbffa70 sp=0x7fff5fbff8f8\r\nruntime.morestack()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:330 +0x7f fp=0x7fff5fbffa78 sp=0x7fff5fbffa70\r\n\r\ngoroutine 1 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a118, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820061b68 sp=0xc820061b40\r\nruntime.goparkunlock(0xc82001a118, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820061ba0 sp=0xc820061b68\r\nruntime.chanrecv(0x41e0760, 0xc82001a0c0, 0xc820061ce8, 0xc820061c01, 0x40e0000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820061c60 sp=0xc820061ba0\r\nruntime.chanrecv2(0x41e0760, 0xc82001a0c0, 0xc820061ce8, 0x51401c8)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820061c90 sp=0xc820061c60\r\ngo4n6/file/mft.(*MFT).Decode(0xc8210fc5a0, 0x51401c8, 0xc8210fc570, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:224 +0x166 fp=0xc820061d28 sp=0xc820061c90\r\ngo4n6/fs/ntfs.(*NTFS).Entries(0xc821bb06a0, 0xc8210fc101, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/fs/ntfs/ntfs.go:130 +0x97 fp=0xc820061d70 sp=0xc820061d28\r\nmain.main()\r\n\t/Users/joe/src/ntfstest.go:43 +0x990 fp=0xc820061f50 sp=0xc820061d70\r\nruntime.main()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:111 +0x2b0 fp=0xc820061fa0 sp=0xc820061f50\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820061fa8 sp=0xc820061fa0\r\n\r\ngoroutine 17 [syscall, locked to thread]:\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820040fb8 sp=0xc820040fb0\r\n\r\ngoroutine 2 [force gc (idle)]:\r\nruntime.gopark(0x42bb1b0, 0x4364860, 0x426f330, 0xf, 0x14, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002c758 sp=0xc82002c730\r\nruntime.goparkunlock(0x4364860, 0x426f330, 0xf, 0xc820000114, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002c790 sp=0xc82002c758\r\nruntime.forcegchelper()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:152 +0xb8 fp=0xc82002c7c0 sp=0xc82002c790\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002c7c8 sp=0xc82002c7c0\r\ncreated by runtime.init.4\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:141 +0x2b\r\n\r\ngoroutine 3 [GC sweep wait]:\r\nruntime.gopark(0x42bb1b0, 0x43649a0, 0x426c130, 0xd, 0x407dc14, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002cf48 sp=0xc82002cf20\r\nruntime.goparkunlock(0x43649a0, 0x426c130, 0xd, 0x14, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002cf80 sp=0xc82002cf48\r\nruntime.bgsweep(0xc820064000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgcsweep.go:67 +0x14d fp=0xc82002cfb8 sp=0xc82002cf80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002cfc0 sp=0xc82002cfb8\r\ncreated by runtime.gcenable\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:205 +0x53\r\n\r\ngoroutine 4 [finalizer wait]:\r\nruntime.gopark(0x42bb1b0, 0x435f288, 0x426eff0, 0xe, 0x14, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002d718 sp=0xc82002d6f0\r\nruntime.goparkunlock(0x435f288, 0x426eff0, 0xe, 0x14, 0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002d750 sp=0xc82002d718\r\nruntime.runfinq()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mfinal.go:154 +0xaa fp=0xc82002d7c0 sp=0xc82002d750\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002d7c8 sp=0xc82002d7c0\r\ncreated by runtime.createfing\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mfinal.go:135 +0x60\r\n\r\ngoroutine 58 [semacquire]:\r\nruntime.gopark(0x42bb1b0, 0x436ad40, 0x4271790, 0xa, 0x19, 0x4)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002fe80 sp=0xc82002fe58\r\nruntime.goparkunlock(0x436ad40, 0x4271790, 0xa, 0xc820033619, 0x4)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002feb8 sp=0xc82002fe80\r\nruntime.semacquire(0xc8205e4b6c, 0x40c2e01)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/sema.go:100 +0x2f7 fp=0xc82002ff18 sp=0xc82002feb8\r\nsync.runtime_Semacquire(0xc8205e4b6c)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/sema.go:43 +0x26 fp=0xc82002ff30 sp=0xc82002ff18\r\nsync.(*WaitGroup).Wait(0xc8205e4b60)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/sync/waitgroup.go:126 +0xb4 fp=0xc82002ff78 sp=0xc82002ff30\r\ngo4n6/ioutil.(*LookaheadReader).start(0xc820600000)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:337 +0xbc fp=0xc82002ffb8 sp=0xc82002ff78\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002ffc0 sp=0xc82002ffb8\r\ncreated by go4n6/ioutil.(*LookaheadReader).Get\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:140 +0x1ec\r\n\r\ngoroutine 59 [garbage collection]:\r\nruntime.systemstack_switch()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:216 fp=0xc822e7f358 sp=0xc822e7f350\r\nruntime.gc(0x1)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:1096 +0x3d0 fp=0xc822e7f650 sp=0xc822e7f358\r\nruntime.startGC(0x1, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:850 +0x101 fp=0xc822e7f670 sp=0xc822e7f650\r\nruntime.mallocgc(0x8000, 0x41e8fe0, 0x1, 0x43650a0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:705 +0x4fb fp=0xc822e7f740 sp=0xc822e7f670\r\nruntime.newarray(0x41e8fe0, 0x8000, 0xc822e7f7d0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:777 +0xc9 fp=0xc822e7f780 sp=0xc822e7f740\r\nruntime.makeslice(0x41e0400, 0x0, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/slice.go:32 +0x165 fp=0xc822e7f7d0 sp=0xc822e7f780\r\ngo4n6/compress/zlib.(*reader).Read(0xc820a2ef00, 0xc824872000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:73 +0xab fp=0xc822e7f8e8 sp=0xc822e7f7d0\r\nio.(*LimitedReader).Read(0xc82092e620, 0xc824872000, 0x8000, 0x8000, 0x8001, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc822e7f938 sp=0xc822e7f8e8\r\nbytes.(*Buffer).ReadFrom(0xc821a1b500, 0x47b1210, 0xc82092e620, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc822e7f9e8 sp=0xc822e7f938\r\nio.copyBuffer(0x47b11e8, 0xc821a1b500, 0x47b1210, 0xc82092e620, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc822e7faa8 sp=0xc822e7f9e8\r\nio.Copy(0x47b11e8, 0xc821a1b500, 0x47b1210, 0xc82092e620, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc822e7fb00 sp=0xc822e7faa8\r\nio.CopyN(0x47b11e8, 0xc821a1b500, 0x47b1198, 0xc820a2ef00, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc822e7fb80 sp=0xc822e7fb00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc82092c060, 0x180ce, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc822e7fe80 sp=0xc822e7fb80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc822e7ff88 sp=0xc822e7fe80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc822e7ff90 sp=0xc822e7ff88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 60 [runnable]:\r\nruntime.shouldtriggergc(0xc822e83480)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:709 fp=0xc822e833d8 sp=0xc822e833d0\r\nruntime.mallocgc(0x12000, 0x41e8fe0, 0x1, 0x8000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:704 +0x4e0 fp=0xc822e834a8 sp=0xc822e833d8\r\nruntime.newarray(0x41e8fe0, 0x10200, 0xc822e83548)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:777 +0xc9 fp=0xc822e834e8 sp=0xc822e834a8\r\nruntime.makeslice(0x41e0400, 0x10200, 0x10200, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/slice.go:32 +0x165 fp=0xc822e83538 sp=0xc822e834e8\r\nbytes.makeSlice(0x10200, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:195 +0x64 fp=0xc822e83588 sp=0xc822e83538\r\nbytes.(*Buffer).ReadFrom(0xc821a3e930, 0x47b1210, 0xc82092c840, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:167 +0xd3 fp=0xc822e83638 sp=0xc822e83588\r\nio.copyBuffer(0x47b11e8, 0xc821a3e930, 0x47b1210, 0xc82092c840, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc822e836f8 sp=0xc822e83638\r\nio.Copy(0x47b11e8, 0xc821a3e930, 0x47b1210, 0xc82092c840, 0x22e83fc000008000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc822e83750 sp=0xc822e836f8\r\nio.CopyN(0x47b11e8, 0xc821a3e930, 0x47a42b0, 0xc820a4a020, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc822e837d0 sp=0xc822e83750\r\ngo4n6/compress/zlib.(*reader).Read(0xc820a64640, 0xc824390000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:75 +0x198 fp=0xc822e838e8 sp=0xc822e837d0\r\nio.(*LimitedReader).Read(0xc82092c820, 0xc824390000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc822e83938 sp=0xc822e838e8\r\nbytes.(*Buffer).ReadFrom(0xc821a3e8c0, 0x47b1210, 0xc82092c820, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc822e839e8 sp=0xc822e83938\r\nio.copyBuffer(0x47b11e8, 0xc821a3e8c0, 0x47b1210, 0xc82092c820, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc822e83aa8 sp=0xc822e839e8\r\nio.Copy(0x47b11e8, 0xc821a3e8c0, 0x47b1210, 0xc82092c820, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc822e83b00 sp=0xc822e83aa8\r\nio.CopyN(0x47b11e8, 0xc821a3e8c0, 0x47b1198, 0xc820a64640, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc822e83b80 sp=0xc822e83b00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc820a4a020, 0x1810d, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc822e83e80 sp=0xc822e83b80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x1)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc822e83f88 sp=0xc822e83e80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc822e83f90 sp=0xc822e83f88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 61 [runnable]:\r\nruntime.shouldtriggergc(0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/mgc.go:709 fp=0xc8210dba20 sp=0xc8210dba18\r\nruntime.mallocgc(0x8000, 0x41e8fe0, 0x1, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:704 +0x4e0 fp=0xc8210dbaf0 sp=0xc8210dba20\r\nruntime.newarray(0x41e8fe0, 0x8000, 0xc8210dbb90)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/malloc.go:777 +0xc9 fp=0xc8210dbb30 sp=0xc8210dbaf0\r\nruntime.makeslice(0x41e0400, 0x0, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/slice.go:32 +0x165 fp=0xc8210dbb80 sp=0xc8210dbb30\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc82092e060, 0x1810f, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:278 +0x314 fp=0xc8210dbe80 sp=0xc8210dbb80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x2)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc8210dbf88 sp=0xc8210dbe80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8210dbf90 sp=0xc8210dbf88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 62 [runnable, locked to thread]:\r\nruntime.cgocall(0x4033b80, 0xc8200637d0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/cgocall.go:120 +0x11b fp=0xc820063788 sp=0xc820063758\r\ngo4n6/compress/zlib._Cfunc_inflate(0xc820a405c8, 0xc800000000, 0x1)\r\n\t??:0 +0x39 fp=0xc8200637d0 sp=0xc820063788\r\ngo4n6/compress/zlib.(*reader).Read(0xc820a405a0, 0xc824082000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:99 +0x3d4 fp=0xc8200638e8 sp=0xc8200637d0\r\nio.(*LimitedReader).Read(0xc820a4a260, 0xc824082000, 0x8000, 0x8000, 0x8001, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc820063938 sp=0xc8200638e8\r\nbytes.(*Buffer).ReadFrom(0xc821a407e0, 0x47b1210, 0xc820a4a260, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc8200639e8 sp=0xc820063938\r\nio.copyBuffer(0x47b11e8, 0xc821a407e0, 0x47b1210, 0xc820a4a260, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc820063aa8 sp=0xc8200639e8\r\nio.Copy(0x47b11e8, 0xc821a407e0, 0x47b1210, 0xc820a4a260, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc820063b00 sp=0xc820063aa8\r\nio.CopyN(0x47b11e8, 0xc821a407e0, 0x47b1198, 0xc820a405a0, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc820063b80 sp=0xc820063b00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc8209200a0, 0x1810a, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc820063e80 sp=0xc820063b80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x3)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc820063f88 sp=0xc820063e80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820063f90 sp=0xc820063f88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 63 [runnable]:\r\nsyscall.Syscall(0x3, 0x7, 0xc8246f4000, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/syscall/asm_darwin_amd64.s:16 +0x5 fp=0xc82005f420 sp=0xc82005f418\r\nsyscall.read(0x7, 0xc8246f4000, 0x8000, 0x8000, 0x407cb80, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/syscall/zsyscall_darwin_amd64.go:972 +0x5f fp=0xc82005f460 sp=0xc82005f420\r\nsyscall.Read(0x7, 0xc8246f4000, 0x8000, 0x8000, 0xc8212cc000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/syscall/syscall_unix.go:160 +0x4d fp=0xc82005f4a0 sp=0xc82005f460\r\nos.(*File).read(0xc820922010, 0xc8246f4000, 0x8000, 0x8000, 0xc820033680, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/os/file_unix.go:211 +0x75 fp=0xc82005f4e0 sp=0xc82005f4a0\r\nos.(*File).Read(0xc820922010, 0xc8246f4000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/os/file.go:95 +0x8a fp=0xc82005f538 sp=0xc82005f4e0\r\nio.(*LimitedReader).Read(0xc82090cf80, 0xc8246f4000, 0x8000, 0x8000, 0x1, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc82005f588 sp=0xc82005f538\r\nbytes.(*Buffer).ReadFrom(0xc821a1a4d0, 0x47b1210, 0xc82090cf80, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc82005f638 sp=0xc82005f588\r\nio.copyBuffer(0x47b11e8, 0xc821a1a4d0, 0x47b1210, 0xc82090cf80, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc82005f6f8 sp=0xc82005f638\r\nio.Copy(0x47b11e8, 0xc821a1a4d0, 0x47b1210, 0xc82090cf80, 0x2005ffc000008000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc82005f750 sp=0xc82005f6f8\r\nio.CopyN(0x47b11e8, 0xc821a1a4d0, 0x47a42b0, 0xc82091e0a0, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc82005f7d0 sp=0xc82005f750\r\ngo4n6/compress/zlib.(*reader).Read(0xc820a72320, 0xc8244f4000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:75 +0x198 fp=0xc82005f8e8 sp=0xc82005f7d0\r\nio.(*LimitedReader).Read(0xc82090cf60, 0xc8244f4000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc82005f938 sp=0xc82005f8e8\r\nbytes.(*Buffer).ReadFrom(0xc821a1a460, 0x47b1210, 0xc82090cf60, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc82005f9e8 sp=0xc82005f938\r\nio.copyBuffer(0x47b11e8, 0xc821a1a460, 0x47b1210, 0xc82090cf60, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc82005faa8 sp=0xc82005f9e8\r\nio.Copy(0x47b11e8, 0xc821a1a460, 0x47b1210, 0xc82090cf60, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc82005fb00 sp=0xc82005faa8\r\nio.CopyN(0x47b11e8, 0xc821a1a460, 0x47b1198, 0xc820a72320, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc82005fb80 sp=0xc82005fb00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc82091e0a0, 0x1810e, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc82005fe80 sp=0xc82005fb80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x4)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc82005ff88 sp=0xc82005fe80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82005ff90 sp=0xc82005ff88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 64 [runnable, locked to thread]:\r\nruntime.cgocall(0x4033b80, 0xc8210dd7d0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/cgocall.go:120 +0x11b fp=0xc8210dd788 sp=0xc8210dd758\r\ngo4n6/compress/zlib._Cfunc_inflate(0xc821ce6348, 0xc800000000, 0x1)\r\n\t??:0 +0x39 fp=0xc8210dd7d0 sp=0xc8210dd788\r\ngo4n6/compress/zlib.(*reader).Read(0xc821ce6320, 0xc8240c6000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:99 +0x3d4 fp=0xc8210dd8e8 sp=0xc8210dd7d0\r\nio.(*LimitedReader).Read(0xc82092e220, 0xc8240c6000, 0x8000, 0x8000, 0x8001, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc8210dd938 sp=0xc8210dd8e8\r\nbytes.(*Buffer).ReadFrom(0xc821cfa4d0, 0x47b1210, 0xc82092e220, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc8210dd9e8 sp=0xc8210dd938\r\nio.copyBuffer(0x47b11e8, 0xc821cfa4d0, 0x47b1210, 0xc82092e220, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc8210ddaa8 sp=0xc8210dd9e8\r\nio.Copy(0x47b11e8, 0xc821cfa4d0, 0x47b1210, 0xc82092e220, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc8210ddb00 sp=0xc8210ddaa8\r\nio.CopyN(0x47b11e8, 0xc821cfa4d0, 0x47b1198, 0xc821ce6320, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc8210ddb80 sp=0xc8210ddb00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc820a70020, 0x1810b, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc8210dde80 sp=0xc8210ddb80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x5)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc8210ddf88 sp=0xc8210dde80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8210ddf90 sp=0xc8210ddf88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 65 [runnable, locked to thread]:\r\nruntime.cgocall(0x4033b80, 0xc8210e17d0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/cgocall.go:120 +0x11b fp=0xc8210e1788 sp=0xc8210e1758\r\ngo4n6/compress/zlib._Cfunc_inflate(0xc820a2e5c8, 0xc800000000, 0x1)\r\n\t??:0 +0x39 fp=0xc8210e17d0 sp=0xc8210e1788\r\ngo4n6/compress/zlib.(*reader).Read(0xc820a2e5a0, 0xc82410a000, 0x8000, 0x8000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/compress/zlib/zlib.go:99 +0x3d4 fp=0xc8210e18e8 sp=0xc8210e17d0\r\nio.(*LimitedReader).Read(0xc82091f780, 0xc82410a000, 0x8000, 0x8000, 0x8001, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc8210e1938 sp=0xc8210e18e8\r\nbytes.(*Buffer).ReadFrom(0xc821a188c0, 0x47b1210, 0xc82091f780, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc8210e19e8 sp=0xc8210e1938\r\nio.copyBuffer(0x47b11e8, 0xc821a188c0, 0x47b1210, 0xc82091f780, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc8210e1aa8 sp=0xc8210e19e8\r\nio.Copy(0x47b11e8, 0xc821a188c0, 0x47b1210, 0xc82091f780, 0x4059d1d, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc8210e1b00 sp=0xc8210e1aa8\r\nio.CopyN(0x47b11e8, 0xc821a188c0, 0x47b1198, 0xc820a2e5a0, 0x8000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc8210e1b80 sp=0xc8210e1b00\r\ngo4n6/disk/ewf.decompress(0x47b1138, 0xc82090c680, 0x1810c, 0x4255fe0, 0xc82009c000, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:279 +0x408 fp=0xc8210e1e80 sp=0xc8210e1b80\r\ngo4n6/ioutil.(*LookaheadReader).start.func1(0xc8205e4b60, 0xc820600000, 0x6)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:325 +0x3f8 fp=0xc8210e1f88 sp=0xc8210e1e80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8210e1f90 sp=0xc8210e1f88\r\ncreated by go4n6/ioutil.(*LookaheadReader).start\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:333 +0x94\r\n\r\ngoroutine 76 [runnable]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a238, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820a3c5b8 sp=0xc820a3c590\r\nruntime.goparkunlock(0xc82001a238, 0x426e910, 0xc, 0x4169e17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820a3c5f0 sp=0xc820a3c5b8\r\nruntime.chanrecv(0x41e07c0, 0xc82001a1e0, 0xc820a3c740, 0x41e8701, 0xc8220c0000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820a3c6b0 sp=0xc820a3c5f0\r\nruntime.chanrecv2(0x41e07c0, 0xc82001a1e0, 0xc820a3c740, 0x41e0400)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820a3c6e0 sp=0xc820a3c6b0\r\ngo4n6/ioutil.(*LookaheadReader).Get(0xc820600000, 0x180ce, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/lookahead.go:161 +0x443 fp=0xc820a3c7c8 sp=0xc820a3c6e0\r\ngo4n6/disk/ewf.(*segment).Read(0xc82009c000, 0xc8234d0000, 0x490000, 0x490000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/disk/ewf/segment.go:114 +0x1ea fp=0xc820a3c858 sp=0xc820a3c7c8\r\ngo4n6/ioutil.(*MultiReadSeeker).Read(0xc82000e6f0, 0xc8234d0000, 0x490000, 0x490000, 0xc0670000, 0x0, 0x0)\r\n\t/Users/joe/go/src/go4n6/ioutil/multi.go:90 +0x204 fp=0xc820a3c928 sp=0xc820a3c858\r\ngo4n6/disk/ewf.(*Reader).Read(0xc8200143c0, 0xc8234d0000, 0x490000, 0x490000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:6 +0x82 fp=0xc820a3c978 sp=0xc820a3c928\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc8210fc120, 0xc8234d0000, 0x490000, 0x490000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120 fp=0xc820a3c9c8 sp=0xc820a3c978\r\ngo4n6/partition/mbr.Partition.Read(0x5540000, 0xc8210fc120, 0xc82008e240, 0xfffffe0700212080, 0x27ff00000000800, 0xc8234d0000, 0x490000, 0x490000, 0xc0570000, 0x0, ...)\r\n\t/Users/joe/go/src/go4n6/partition/mbr/partition.go:388 +0x6d fp=0xc820a3ca18 sp=0xc820a3c9c8\r\ngo4n6/partition/mbr.(*Partition).Read(0xc8210fc150, 0xc8234d0000, 0x490000, 0x490000, 0x0, 0x0, 0x0)\r\n\t<autogenerated>:4 +0xc8 fp=0xc820a3ca78 sp=0xc820a3ca18\r\ngithub.com/badgerodon/ioutil.(*SectionReader).Read(0xc8210fc4e0, 0xc8234d0000, 0x490000, 0x490000, 0x0, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/section.go:41 +0x120 fp=0xc820a3cac8 sp=0xc820a3ca78\r\ngithub.com/badgerodon/ioutil.(*MultiReadSeeker).Read(0xc8210fc540, 0xc8234d0000, 0x490000, 0x490000, 0x8000, 0x0, 0x0)\r\n\t/Users/joe/go/src/github.com/badgerodon/ioutil/multi.go:39 +0x204 fp=0xc820a3cb98 sp=0xc820a3cac8\r\ngo4n6/ioutil.(*MultiRangeReadSeeker).Read(0xc8210fc570, 0xc8234d0000, 0x490000, 0x490000, 0x8000, 0x0, 0x0)\r\n\t<autogenerated>:24 +0x82 fp=0xc820a3cbe8 sp=0xc820a3cb98\r\nio.(*LimitedReader).Read(0xc821bb06c0, 0xc8234d0000, 0x490000, 0x490000, 0x8000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:427 +0xbd fp=0xc820a3cc38 sp=0xc820a3cbe8\r\nbytes.(*Buffer).ReadFrom(0xc821cfa460, 0x47b1210, 0xc821bb06c0, 0x570000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/bytes/buffer.go:173 +0x23f fp=0xc820a3cce8 sp=0xc820a3cc38\r\nio.copyBuffer(0x47b11e8, 0xc821cfa460, 0x47b1210, 0xc821bb06c0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:375 +0x180 fp=0xc820a3cda8 sp=0xc820a3cce8\r\nio.Copy(0x47b11e8, 0xc821cfa460, 0x47b1210, 0xc821bb06c0, 0xc82001a120, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:351 +0x64 fp=0xc820a3ce00 sp=0xc820a3cda8\r\nio.CopyN(0x47b11e8, 0xc821cfa460, 0x51401c8, 0xc8210fc570, 0xa00000, 0xa00000, 0x0, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/io/io.go:327 +0xf7 fp=0xc820a3ce80 sp=0xc820a3ce00\r\ngo4n6/file/mft.(*MFT).decodeEntries(0xc8210fc5a0, 0x51401c8, 0xc8210fc570, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:92 +0x22f fp=0xc820a3cf90 sp=0xc820a3ce80\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820a3cf98 sp=0xc820a3cf90\r\ncreated by go4n6/file/mft.(*MFT).Decode\r\n\t/Users/joe/go/src/go4n6/file/mft/mft.go:221 +0x123\r\n\r\ngoroutine 79 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820a2a620 sp=0xc820a2a5f8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0xc820d4e517, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820a2a658 sp=0xc820a2a620\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc820a2a768, 0xc820a2a701, 0xc820a20000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820a2a718 sp=0xc820a2a658\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc820a2a768, 0xc820d4e900)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820a2a748 sp=0xc820a2a718\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc820a2a7a0 sp=0xc820a2a748\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820a2a7a8 sp=0xc820a2a7a0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 78 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820a2ae20 sp=0xc820a2adf8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0xc820d50517, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820a2ae58 sp=0xc820a2ae20\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc820a2af68, 0xc820a2af01, 0xc820a20000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820a2af18 sp=0xc820a2ae58\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc820a2af68, 0xc820d50900)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820a2af48 sp=0xc820a2af18\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc820a2afa0 sp=0xc820a2af48\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820a2afa8 sp=0xc820a2afa0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 77 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820a2b620 sp=0xc820a2b5f8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x407e417, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820a2b658 sp=0xc820a2b620\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc820a2b768, 0xc820a2b701, 0xc820a20000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820a2b718 sp=0xc820a2b658\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc820a2b768, 0xc820d52900)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820a2b748 sp=0xc820a2b718\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc820a2b7a0 sp=0xc820a2b748\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820a2b7a8 sp=0xc820a2b7a0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 80 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002b620 sp=0xc82002b5f8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x42bbc17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002b658 sp=0xc82002b620\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc82002b768, 0xc82002b701, 0xc820020000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc82002b718 sp=0xc82002b658\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc82002b768, 0xc8205e45d0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc82002b748 sp=0xc82002b718\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc82002b7a0 sp=0xc82002b748\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002b7a8 sp=0xc82002b7a0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 81 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002ee20 sp=0xc82002edf8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x42bbc17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002ee58 sp=0xc82002ee20\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc82002ef68, 0xc82002ef01, 0xc820020000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc82002ef18 sp=0xc82002ee58\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc82002ef68, 0xc8205e4a10)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc82002ef48 sp=0xc82002ef18\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc82002efa0 sp=0xc82002ef48\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002efa8 sp=0xc82002efa0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 82 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc82002de20 sp=0xc82002ddf8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x42bbc17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc82002de58 sp=0xc82002de20\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc82002df68, 0xc82002df01, 0xc820020000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc82002df18 sp=0xc82002de58\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc82002df68, 0xc8205e4a10)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc82002df48 sp=0xc82002df18\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc82002dfa0 sp=0xc82002df48\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc82002dfa8 sp=0xc82002dfa0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 83 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820028620 sp=0xc8200285f8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820028658 sp=0xc820028620\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc820028768, 0xc820028701, 0xc820020000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820028718 sp=0xc820028658\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc820028768, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820028748 sp=0xc820028718\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc8200287a0 sp=0xc820028748\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc8200287a8 sp=0xc8200287a0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\n\r\ngoroutine 84 [chan receive]:\r\nruntime.gopark(0x42bb1b0, 0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:185 +0x163 fp=0xc820028e20 sp=0xc820028df8\r\nruntime.goparkunlock(0xc82001a178, 0x426e910, 0xc, 0x17, 0x3)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/proc.go:191 +0x54 fp=0xc820028e58 sp=0xc820028e20\r\nruntime.chanrecv(0x41e0700, 0xc82001a120, 0xc820028f68, 0xc820028f01, 0xc820020000)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:505 +0x901 fp=0xc820028f18 sp=0xc820028e58\r\nruntime.chanrecv2(0x41e0700, 0xc82001a120, 0xc820028f68, 0x0)\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/chan.go:354 +0x2b fp=0xc820028f48 sp=0xc820028f18\r\ngo4n6/file/mft.(*MFT).decodeEntries.func1(0xc82000adf0, 0xc82001a120, 0xc8210fc5a0, 0xc82001a0c0)\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:80 +0x79 fp=0xc820028fa0 sp=0xc820028f48\r\nruntime.goexit()\r\n\t/usr/local/Cellar/go/1.5rc1/libexec/src/runtime/asm_amd64.s:1696 +0x1 fp=0xc820028fa8 sp=0xc820028fa0\r\ncreated by go4n6/file/mft.(*MFT).decodeEntries\r\n\t/Users/joe/go/src/go4n6/file/mft/entry.go:86 +0x109\r\nexit status 2\r\n```\n\n\n#### Comment by @aclements (2015-08-14 15:56:14)\n\nThanks for the quick reply, @jtsylve.\r\n\r\n>         r.s.next_in = (*C.Bytef)(unsafe.Pointer(&buf.Bytes()[0]))\r\n\r\nis definitely not safe. As soon as you leave that scope, the backing store of buf will be reachable only through the C heap (via the z_stream_s object malloc'd by inflateInit). Since the GC can't trace through the C heap, it's free to free buf. At that point all bets are off. I'm actually kind of surprised this works in 1.4.2. I think you're just getting lucky.\r\n\r\nDepending on where p comes from, the same may be true of\r\n\r\n> r.s.next_out = (*C.Bytef)(unsafe.Pointer(&out[0]))\n\n#### Comment by @jtsylve (2015-08-14 18:29:20)\n\nHow can I achieve a similar result that is considered \"safe\" unsafe code?\n\n#### Comment by @jtsylve (2015-08-15 01:20:52)\n\nSo I fixed the scoping issue.  That wasn't the problem that was causing panics; however, I was able to figure out what was.\r\n\r\nThe `C.z_stream` structure was being allocated by cgo.  `zlib` then allocates pointers inside of that struct and the Go GC saw them as invalid (since it had no record of the allocations).  The solution was to only store a pointer to `z_stream` sized data so that the GC wouldn't do pointer inspection on it.\r\n\r\nI assume this is intended behavior for the GC, but it is a real \"gotya\" and should be added to that new cgo documentation that was mentioned.\r\n\r\nFor reference here's the updated (working) code.\r\n\r\ndiff:\r\n```diff\r\n@@ -23,11 +23,16 @@ package zlib\r\n \r\n // #cgo LDFLAGS: -lz\r\n // #include <zlib.h>\r\n+// #include <stdlib.h>\r\n //\r\n // // inflateInit is a macro so we need to do this\r\n // int InflateInit(z_streamp s) {\r\n //     return inflateInit(s);\r\n // }\r\n+//\r\n+// z_streamp new_zstream() {\r\n+//     return (z_streamp) calloc(sizeof(z_stream), 1);\r\n+// }\r\n import \"C\"\r\n \r\n import (\r\n@@ -40,7 +45,7 @@ import (\r\n type reader struct {\r\n \tr     io.Reader\r\n \tinbuf []byte\r\n-\ts     C.z_stream\r\n+\ts     *C.z_stream\r\n }\r\n \r\n // NewReader creates a new ReadCloser. Reads from the returned ReadCloser\r\n@@ -50,9 +55,10 @@ type reader struct {\r\n func NewReader(r io.Reader) (io.ReadCloser, error) {\r\n \trd := &reader{\r\n \t\tr: r,\r\n+\t\ts: C.new_zstream(),\r\n \t}\r\n \r\n-\terr := C.InflateInit(&rd.s)\r\n+\terr := C.InflateInit(rd.s)\r\n \tif err != C.Z_OK {\r\n \t\treturn nil, errors.New(\"Could not init inflate.\")\r\n \t}\r\n@@ -69,8 +75,9 @@ func (r *reader) Read(p []byte) (n int, err error) {\r\n \t// output.\r\n \tmaxIn := int64(len(p))\r\n \r\n+\tvar buf *bytes.Buffer\r\n \tif r.inbuf == nil {\r\n-\t\tbuf := bytes.NewBuffer(make([]byte, 0, maxIn))\r\n+\t\tbuf = bytes.NewBuffer(make([]byte, 0, maxIn))\r\n \r\n \t\tnIn, err := io.CopyN(buf, r.r, maxIn)\r\n \t\tif err != nil && err != io.EOF {\r\n@@ -96,7 +103,7 @@ func (r *reader) Read(p []byte) (n int, err error) {\r\n \t\tr.s.avail_out = C.uInt(len(out))\r\n \t\tr.s.next_out = (*C.Bytef)(unsafe.Pointer(&out[0]))\r\n \r\n-\t\tret = C.inflate(&r.s, C.Z_NO_FLUSH)\r\n+\t\tret = C.inflate(r.s, C.Z_NO_FLUSH)\r\n \r\n \t\tif ret != C.Z_STREAM_END && ret != C.Z_OK {\r\n \t\t\treturn 0, errors.New(\"Could not deflate input.\")\r\n@@ -126,10 +133,12 @@ func (r *reader) Read(p []byte) (n int, err error) {\r\n //\r\n // Calling Close does not close the wrapped io.Reader originally passed to NewReader\r\n func (r *reader) Close() error {\r\n-\terr := C.inflateEnd(&r.s)\r\n+\terr := C.inflateEnd(r.s)\r\n \tif err != C.Z_OK {\r\n \t\treturn errors.New(\"Could not end inflate\")\r\n \t}\r\n \r\n+\tC.free(unsafe.Pointer(r.s))\r\n+\r\n \treturn nil\r\n }\r\n```\r\n\r\nFull code:\r\n\r\n```go\r\n// #cgo LDFLAGS: -lz\r\n// #include <zlib.h>\r\n// #include <stdlib.h>\r\n//\r\n// // inflateInit is a macro so we need to do this\r\n// int InflateInit(z_streamp s) {\r\n//     return inflateInit(s);\r\n// }\r\n//\r\n// z_streamp new_zstream() {\r\n//     return (z_streamp) calloc(sizeof(z_stream), 1);\r\n// }\r\nimport \"C\"\r\n\r\nimport (\r\n\t\"bytes\"\r\n\t\"errors\"\r\n\t\"io\"\r\n\t\"unsafe\"\r\n)\r\n\r\ntype reader struct {\r\n\tr     io.Reader\r\n\tinbuf []byte\r\n\ts     *C.z_stream\r\n}\r\n\r\n// NewReader creates a new ReadCloser. Reads from the returned ReadCloser\r\n// read and decompress data from r. The implementation buffers input and\r\n// may read more data than necessary from r. It is the caller's\r\n// responsibility to call Close on the ReadCloser when done.\r\nfunc NewReader(r io.Reader) (io.ReadCloser, error) {\r\n\trd := &reader{\r\n\t\tr: r,\r\n\t\ts: C.new_zstream(),\r\n\t}\r\n\r\n\terr := C.InflateInit(rd.s)\r\n\tif err != C.Z_OK {\r\n\t\treturn nil, errors.New(\"Could not init inflate.\")\r\n\t}\r\n\r\n\treturn rd, nil\r\n}\r\n\r\nfunc (r *reader) Read(p []byte) (n int, err error) {\r\n\tif len(p) == 0 {\r\n\t\treturn 0, nil\r\n\t}\r\n\r\n\t// We can assume that the input will be smaller than\r\n\t// output.\r\n\tmaxIn := int64(len(p))\r\n\r\n\tvar buf *bytes.Buffer\r\n\tif r.inbuf == nil {\r\n\t\tbuf = bytes.NewBuffer(make([]byte, 0, maxIn))\r\n\r\n\t\tnIn, err := io.CopyN(buf, r.r, maxIn)\r\n\t\tif err != nil && err != io.EOF {\r\n\t\t\treturn 0, err\r\n\t\t}\r\n\r\n\t\tif nIn == 0 && err == io.EOF {\r\n\t\t\treturn 0, io.ErrUnexpectedEOF\r\n\t\t}\r\n\r\n\t\tr.s.avail_in = C.uInt(nIn)\r\n\t\tr.s.next_in = (*C.Bytef)(unsafe.Pointer(&buf.Bytes()[0]))\r\n\t} else {\r\n\t\t// We still have input from the last call\r\n\t\tr.s.avail_in = C.uInt(len(r.inbuf))\r\n\t\tr.s.next_in = (*C.Bytef)(unsafe.Pointer(&r.inbuf[0]))\r\n\t}\r\n\r\n\tvar read int\r\n\tvar ret C.int\r\n\tfor ret != C.Z_STREAM_END {\r\n\t\tout := p[read:]\r\n\t\tr.s.avail_out = C.uInt(len(out))\r\n\t\tr.s.next_out = (*C.Bytef)(unsafe.Pointer(&out[0]))\r\n\r\n\t\tret = C.inflate(r.s, C.Z_NO_FLUSH)\r\n\r\n\t\tif ret != C.Z_STREAM_END && ret != C.Z_OK {\r\n\t\t\treturn 0, errors.New(\"Could not deflate input.\")\r\n\t\t}\r\n\r\n\t\tread = len(out) - int(r.s.avail_out)\r\n\r\n\t\tif r.s.avail_out == 0 {\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\r\n\tif ret == C.Z_STREAM_END {\r\n\t\treturn read, io.EOF\r\n\t}\r\n\r\n\tif r.s.avail_in == 0 {\r\n\t\tr.inbuf = nil\r\n\t} else {\r\n\t\tr.inbuf = C.GoBytes(unsafe.Pointer(r.s.next_in), C.int(r.s.avail_in))\r\n\t}\r\n\r\n\treturn read, nil\r\n}\r\n\r\n// Close implements the io.Closer interface\r\n//\r\n// Calling Close does not close the wrapped io.Reader originally passed to NewReader\r\nfunc (r *reader) Close() error {\r\n\terr := C.inflateEnd(r.s)\r\n\tif err != C.Z_OK {\r\n\t\treturn errors.New(\"Could not end inflate\")\r\n\t}\r\n\r\n\tC.free(unsafe.Pointer(r.s))\r\n\r\n\treturn nil\r\n}\r\n```\n\n\n#### Comment by @aclements (2015-08-15 02:29:34)\n\nSorry, I'm in New Hampshire right now and my Internet barely works, but I'm\ntrying to keep up.\n\nJoe, I'm afraid your code still has the problem I said. You're storing a\npointer to an object allocated on the Go heap in an object allocated on the\nC heap. If you're going to do that, you must keep a reference to that\nobject from the Go heap for at least as long as it's accessible from C.\nOtherwise there's simply no way the garbage collector can know it needs to\nkeep that object around. In general, it's much better to not do this at all\nand to allocate any such pointers from the C heap.\n\nAlso, there's nothing wrong with storing a pointer to the C heap in a Go\nobject. In fact, you're still doing exactly that, you're just storing a\npointer to a pointer now.\n\n\n\n#### Comment by @aclements (2015-08-15 02:36:01)\n\nBTW, @zeebo, if you have any other panics of this form (or other forms, for that matter), just having more samples would be very helpful for establishing or ruling out patterns.\n\n\n#### Comment by @jtsylve (2015-08-15 02:40:03)\n\nInitially I wasn't storing a pointer to a C heap, I was allocating the struct directly on the Go heap (`C.z_stream` vs `*C.z_stream`) and passing it to C.  Since CG had access to the entire struct it was causing panics by the pointers inside that struct that were initialized by `zlib`.  Now I'm just storing a pointer to the C heap, so there are no such errors.  This is likely the better way of doing it since none of those pointers need to be garbage collected anyway.  Again, I assume that this is intended behavior, but it was non obvious (at least to me) so it might be nice to document it.\r\n\r\nAs far as the scoping issues, I may be missing something.  The `buf` and `p` variables that I'm passing pointers to C don't go out of scope until the function returns.  At that point `libz` is finished using them.  I suppose those pointers are still stored in the `z_stream` struct, but they shouldn't be accessed.  That being said, since there are no guarantees that a future version of `libz` won't invalidate this assumption, I suppose I should be storing them in the same scope as the `z_stream` pointer (In my case inside of the `Reader` struct).  \n\n\n#### Comment by @aclements (2015-08-15 03:04:43)\n\nIn my copy of zlib, z_stream is a pointer type and inflateInit mallocs\nmemory and returns the z_stream pointer to it. Perhaps your version is\ndifferent.\n\nAnd, again, even if it were a struct and it contained pointers initialized\nby zlib, that would be perfectly fine because the Go heap is allowed to\npoint to the C heap.\n\nSorry, I was sloppy when I said \"scope.\" In fact, the garbage collector is\nfree to free buf the moment after you last mention it in your code, which\nis before the inflate call.\n\n\n\n#### Comment by @jtsylve (2015-08-15 03:29:35)\n\n>In my copy of zlib, z_stream is a pointer type and inflateInit mallocs\r\n>memory and returns the z_stream pointer to it. Perhaps your version is\r\n>different.\r\n\r\nIndeed it must be (from zlib.h shipped with OS X) \r\n\r\n```C\r\ntypedef struct z_stream_s {\r\n    Bytef    *next_in;  /* next input byte */\r\n    uInt     avail_in;  /* number of bytes available at next_in */\r\n    uLong    total_in;  /* total nb of input bytes read so far */\r\n\r\n    Bytef    *next_out; /* next output byte should be put there */\r\n    uInt     avail_out; /* remaining free space at next_out */\r\n    uLong    total_out; /* total nb of bytes output so far */\r\n\r\n    char     *msg;      /* last error message, NULL if no error */\r\n    struct internal_state FAR *state; /* not visible by applications */\r\n\r\n    alloc_func zalloc;  /* used to allocate the internal state */\r\n    free_func  zfree;   /* used to free the internal state */\r\n    voidpf     opaque;  /* private data object passed to zalloc and zfree */\r\n\r\n    int     data_type;  /* best guess about the data type: binary or text */\r\n    uLong   adler;      /* adler32 value of the uncompressed data */\r\n    uLong   reserved;   /* reserved for future use */\r\n} z_stream;\r\n\r\ntypedef z_stream FAR *z_streamp;\r\n```\r\n```C\r\nZEXTERN int ZEXPORT inflateInit OF((z_streamp strm));\r\n```\r\nAll the more reason not to make assumptions about library changes.\r\n\r\n>And, again, even if it were a struct and it contained pointers initialized\r\n>by zlib, that would be perfectly fine because the Go heap is allowed to\r\n>point to the C heap.\r\n\r\nWhat about pointers to the Go heap that C adjusts? In the above case the `next_in` pointer is actually adjusted by the call to `inflate`.  So now what the GC would see is a pointer into the middle of a GO allocation that it didn't set.  I'm not familiar enough with the GC internals to know if that's a problem, but the panic suggests that it is.  (Especially since this fix does prevent the panic)\r\n\r\n> Sorry, I was sloppy when I said \"scope.\" In fact, the garbage collector is\r\n> free to free buf the moment after you last mention it in your code, which\r\n> is before the inflate call.\r\n\r\nThat is something I didn't know about the GC!  I wouldn't have assumed that was the case since the reference is still being stored in the variable, but it does make sense.\n\n\n#### Comment by @jtsylve (2015-08-15 03:40:11)\n\nSomething else I just noticed is that some of those pointers in `z_stream` are actually function pointers (`alloc_func` & `free_func`), so they wouldn't likely be pointing at the C heap.  The GC may have taken issue with those."}}