New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/mobile: App crashed on startup. #26009

C-ollins opened this Issue Jun 22, 2018 · 2 comments


None yet
3 participants

C-ollins commented Jun 22, 2018

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version go1.10.3 linux/amd64

Does this issue reproduce with the latest release?


What operating system and processor architecture are you using (go env)?

linux amd64

What did you do?

Crashes on second run of the app, doesn't crash at first. It crashes at launch every 2 intervals.

If possible, provide a recipe for reproducing the error.
All you need is to run the app.
Source Code

What did you expect to see?

A successful launch

What did you see instead?

Crashed app
Log output:

06-22 09:57:41.166 19102-0/com.dcrandroid E/Go: runtime: writebarrierptr *0x93a31398 = 0x6ce
    fatal error: bad pointer in write barrier
06-22 09:57:41.174 19102-0/com.dcrandroid E/Go: runtime stack:
    runtime.throw(0x934411d5, 0x1c)
    	/usr/local/go/src/runtime/panic.go:616 +0x64
06-22 09:57:41.175 19102-0/com.dcrandroid E/Go: runtime.writebarrierptr.func1()
    	/usr/local/go/src/runtime/mbarrier.go:215 +0x94
    	/usr/local/go/src/runtime/asm_arm.s:349 +0x8c
    goroutine 17 [running, locked to thread]:
    	/usr/local/go/src/runtime/asm_arm.s:294 +0x4 fp=0x4f94af38 sp=0x4f94af34 pc=0x930fb5e4
    runtime.writebarrierptr(0x93a31398, 0x6ce)
    	/usr/local/go/src/runtime/mbarrier.go:213 +0x84 fp=0x4f94af50 sp=0x4f94af38 pc=0x930b3930
    	/home/collins/go/src/, 0x6ce)
06-22 09:57:41.176 19102-0/com.dcrandroid E/Go: 	_cgo_gotypes.go:66 +0x78 fp=0x4f94af60 sp=0x4f94af50 pc=0x93416260
    runtime.call16(0x0, 0xbeca8130, 0xbeca81c4, 0x8, 0x0)
    	/usr/local/go/src/runtime/asm_arm.s:518 +0x4c fp=0x4f94af74 sp=0x4f94af60 pc=0x930fba48
    	/usr/local/go/src/runtime/cgocall.go:316 +0x150 fp=0x4f94afb4 sp=0x4f94af74 pc=0x930a3c0c
    	/usr/local/go/src/runtime/cgocall.go:194 +0xa4 fp=0x4f94afe4 sp=0x4f94afb4 pc=0x930a3a40
    runtime.cgocallback_gofunc(0x0, 0x0, 0x0, 0x4f94c000)
    	/usr/local/go/src/runtime/asm_arm.s:720 +0x7c fp=0x4f94aff0 sp=0x4f94afe4 pc=0x930fd368
    	/usr/local/go/src/runtime/asm_arm.s:1015 +0x4 fp=0x4f94aff0 sp=0x4f94aff0 pc=0x930fd664
    goroutine 5 [runnable]:
    syscall.Syscall(0x3, 0x27, 0x4f9aa000, 0x400, 0x57, 0x0, 0x0)
    	/usr/local/go/src/syscall/asm_linux_arm.s:17 +0x8, 0x4f9aa000, 0x400, 0x400, 0xffffff01, 0x0, 0x0)
    	/usr/local/go/src/syscall/zsyscall_linux_arm.go:749 +0x44
    syscall.Read(0x27, 0x4f9aa000, 0x400, 0x400, 0xffffffff, 0x93835b40, 0x939eca14)
    	/usr/local/go/src/syscall/syscall_unix.go:162 +0x34
06-22 09:57:41.177 19102-0/com.dcrandroid E/Go: internal/poll.(*FD).Read(0x4f96a100, 0x4f9aa000, 0x400, 0x400, 0x0, 0x0, 0x0)
    	/usr/local/go/src/internal/poll/fd_unix.go:153 +0xf0
    os.(*File).read(0x4f92a170, 0x4f9aa000, 0x400, 0x400, 0x0, 0x930b22c8, 0x930b2bf8)
    	/usr/local/go/src/os/file_unix.go:226 +0x3c
    os.(*File).Read(0x4f92a170, 0x4f9aa000, 0x400, 0x400, 0x1, 0x0, 0x0)
    	/usr/local/go/src/os/file.go:107 +0x4c
    	/usr/local/go/src/bufio/bufio.go:100 +0x104
    bufio.(*Reader).ReadSlice(0x4f939fb8, 0x92ea960a, 0x0, 0x0, 0x0, 0x0, 0x0)
    	/usr/local/go/src/bufio/bufio.go:341 +0x1c
    bufio.(*Reader).ReadLine(0x4f939fb8, 0x400, 0x400, 0x4f9aa000, 0x400, 0x400, 0x0)
    	/usr/local/go/src/bufio/bufio.go:370 +0x24, 0x6)
    	/home/collins/go/src/ +0x98
    created by
    	/home/collins/go/src/ +0x10c
    goroutine 6 [IO wait]:
06-22 09:57:41.178 19102-0/com.dcrandroid E/Go: internal/poll.runtime_pollWait(0x92972e80, 0x72, 0x4f9aa400)
    	/usr/local/go/src/runtime/netpoll.go:173 +0x44
    internal/poll.(*pollDesc).wait(0x4f96a194, 0x72, 0xffffff01, 0x93835b40, 0x939eca14)
    	/usr/local/go/src/internal/poll/fd_poll_runtime.go:85 +0xa0
    internal/poll.(*pollDesc).waitRead(0x4f96a194, 0x4f9aa401, 0x400, 0x400)
    	/usr/local/go/src/internal/poll/fd_poll_runtime.go:90 +0x2c
    internal/poll.(*FD).Read(0x4f96a180, 0x4f9aa400, 0x400, 0x400, 0x0, 0x0, 0x0)
    	/usr/local/go/src/internal/poll/fd_unix.go:157 +0x150
    os.(*File).read(0x4f92a180, 0x4f9aa400, 0x400, 0x400, 0x0, 0x0, 0x0)
    	/usr/local/go/src/os/file_unix.go:226 +0x3c
    os.(*File).Read(0x4f92a180, 0x4f9aa400, 0x400, 0x400, 0x0, 0x0, 0x0)
    	/usr/local/go/src/os/file.go:107 +0x4c
    	/usr/local/go/src/bufio/bufio.go:100 +0x104
    bufio.(*Reader).ReadSlice(0x4f93a7b8, 0x92ea960a, 0x0, 0x0, 0x0, 0x0, 0x0)
    	/usr/local/go/src/bufio/bufio.go:341 +0x1c
06-22 09:57:41.179 19102-0/com.dcrandroid E/Go: bufio.(*Reader).ReadLine(0x4f93a7b8, 0x400, 0x400, 0x4f9aa400, 0x400, 0x400, 0x0)
    	/usr/local/go/src/bufio/bufio.go:370 +0x24, 0x4)
    	/home/collins/go/src/ +0x98
    created by
    	/home/collins/go/src/ +0x1c8
    goroutine 22 [syscall]:
    	/usr/local/go/src/runtime/sigqueue.go:139 +0x14c
    	/usr/local/go/src/os/signal/signal_unix.go:22 +0x14
    created by os/signal.init.0
    	/usr/local/go/src/os/signal/signal_unix.go:28 +0x34
    goroutine 23 [select, locked to thread]:
    runtime.gopark(0x93833b64, 0x0, 0x934359f8, 0x6, 0x18, 0x1)
    	/usr/local/go/src/runtime/proc.go:291 +0x10c
06-22 09:57:41.180 19102-0/com.dcrandroid E/Go: runtime.selectgo(0x4f9367a0, 0x4fda2100)
    	/usr/local/go/src/runtime/select.go:392 +0xee4
    	/usr/local/go/src/runtime/signal_unix.go:549 +0x1e0
    	/usr/local/go/src/runtime/asm_arm.s:1015 +0x4
    --------- beginning of crash
06-22 09:57:41.183 19102-19102/com.dcrandroid A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 19102 (com.dcrandroid)

@gopherbot gopherbot added this to the Unreleased milestone Jun 22, 2018

@gopherbot gopherbot added the mobile label Jun 22, 2018


This comment has been minimized.


ianlancetaylor commented Jun 22, 2018

This kind of error normally means that you have a non-pointer value that you have converted to a pointer type, probably when making a call out of Go. In Go, variables of pointer type must always hold pointer values.


This comment has been minimized.

C-ollins commented Jun 25, 2018

Everything shown in the stacktrace is not from my code. Everything is from gomobile. I don't have any null pointer in my code and nothing passes null, the worst from is an empty string, never null.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment