I follow the steps from readme but it get:
SIGSYS: bad system call
PC=0x1056f03 m=0 sigcode=0
goroutine 0 [idle]:
runtime.mach_semaphore_timedwait(0x1300000e03, 0x3b9ac413, 0x7fff5fbfe554, 0x13, 0x3b9ac4135fbfe570, 0x13f95a0, 0x7fff5fbfe588, 0x1051443, 0x4a817c213, 0x103230a, ...)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/sys_darwin_amd64.s:425 +0x13
runtime.semasleep1(0x4a817c213, 0x103230a)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/os_darwin.go:402 +0xe1
runtime.semasleep.func1()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/os_darwin.go:432 +0x33
runtime.systemstack(0x13f9500)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/asm_amd64.s:327 +0x79
runtime.mstart()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/proc.go:1132
goroutine 3 [syscall]:
runtime.notetsleepg(0x13f8d98, 0x4a817c213, 0x16)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/lock_sema.go:257 +0x4b fp=0xc420031f60 sp=0xc420031f20
runtime.timerproc()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/time.go:209 +0x327 fp=0xc420031fe0 sp=0xc420031f60
runtime.goexit()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/asm_amd64.s:2197 +0x1 fp=0xc420031fe8 sp=0xc420031fe0
created by runtime.addtimerLocked
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/time.go:116 +0xed
goroutine 1 [select]:
github.com/facebookgo/grace/gracehttp.(*app).run(0xc420078230, 0x3, 0x3)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:165 +0x403
github.com/facebookgo/grace/gracehttp.Serve(0xc4200e24c0, 0x3, 0x3, 0xc420084d50, 0x0)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:193 +0x4d
main.main()
/Users/sheerun/go/src/github.com/sheerun/demo/main.go:28 +0x24e
goroutine 17 [syscall, locked to thread]:
runtime.goexit()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/asm_amd64.s:2197 +0x1
goroutine 20 [syscall]:
os/signal.signal_recv(0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/sigqueue.go:116 +0xff
os/signal.loop()
/usr/local/Cellar/go/1.8.3/libexec/src/os/signal/signal_unix.go:22 +0x22
created by os/signal.init.1
/usr/local/Cellar/go/1.8.3/libexec/src/os/signal/signal_unix.go:28 +0x41
goroutine 21 [select]:
github.com/facebookgo/httpdown.(*server).manage(0xc4200bc4d0)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:204 +0xa2b
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:96 +0x3df
goroutine 22 [IO wait]:
net.runtime_pollWait(0x1619038, 0x72, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/netpoll.go:164 +0x59
net.(*pollDesc).wait(0xc420078308, 0x72, 0x0, 0xc420144000)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:75 +0x38
net.(*pollDesc).waitRead(0xc420078308, 0xffffffffffffffff, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:80 +0x34
net.(*netFD).accept(0xc4200782a0, 0x0, 0x13ca380, 0xc420144000)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_unix.go:430 +0x1e5
net.(*TCPListener).accept(0xc42009c020, 0xc420042eb0, 0x11f680e, 0x1052350)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock_posix.go:136 +0x2e
net.(*TCPListener).Accept(0xc42009c020, 0x12c2660, 0xc420140000, 0x13ce4c0, 0xc42010a0c0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock.go:228 +0x49
net/http.(*Server).Serve(0xc4200bc2c0, 0x13cdd80, 0xc42009c020, 0x0, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2643 +0x228
github.com/facebookgo/httpdown.(*server).serve(0xc4200bc4d0)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:277 +0x83
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:97 +0x401
goroutine 23 [select]:
github.com/facebookgo/httpdown.(*server).manage(0xc4200bc580)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:204 +0xa2b
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:96 +0x3df
goroutine 24 [IO wait]:
net.runtime_pollWait(0x1618f78, 0x72, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/netpoll.go:164 +0x59
net.(*pollDesc).wait(0xc420078378, 0x72, 0x0, 0xc42000c4e0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:75 +0x38
net.(*pollDesc).waitRead(0xc420078378, 0xffffffffffffffff, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:80 +0x34
net.(*netFD).accept(0xc420078310, 0x0, 0x13ca380, 0xc42000c4e0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_unix.go:430 +0x1e5
net.(*TCPListener).accept(0xc42009c028, 0xc42001c3c0, 0x125fb00, 0x13ef9b0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock_posix.go:136 +0x2e
net.(*TCPListener).Accept(0xc42009c028, 0xc42001c390, 0x125fb00, 0x13ef9b0, 0x1287f80)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock.go:228 +0x49
net/http.(*Server).Serve(0xc4200bc370, 0x13cdd80, 0xc42009c028, 0x0, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2643 +0x228
github.com/facebookgo/httpdown.(*server).serve(0xc4200bc580)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:277 +0x83
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:97 +0x401
goroutine 25 [select]:
github.com/facebookgo/httpdown.(*server).manage(0xc4200bc630)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:204 +0xa2b
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:96 +0x3df
goroutine 26 [IO wait]:
net.runtime_pollWait(0x1618eb8, 0x72, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/netpoll.go:164 +0x59
net.(*pollDesc).wait(0xc4200783e8, 0x72, 0x0, 0xc42000c500)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:75 +0x38
net.(*pollDesc).waitRead(0xc4200783e8, 0xffffffffffffffff, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:80 +0x34
net.(*netFD).accept(0xc420078380, 0x0, 0x13ca380, 0xc42000c500)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_unix.go:430 +0x1e5
net.(*TCPListener).accept(0xc42009c030, 0xc42001c4b0, 0x125fb00, 0x13ef9b0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock_posix.go:136 +0x2e
net.(*TCPListener).Accept(0xc42009c030, 0xc42001c480, 0x125fb00, 0x13ef9b0, 0x1287f80)
/usr/local/Cellar/go/1.8.3/libexec/src/net/tcpsock.go:228 +0x49
net/http.(*Server).Serve(0xc4200bc420, 0x13cdd80, 0xc42009c030, 0x0, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2643 +0x228
github.com/facebookgo/httpdown.(*server).serve(0xc4200bc630)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:277 +0x83
created by github.com/facebookgo/httpdown.HTTP.Serve
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:97 +0x401
goroutine 27 [semacquire]:
sync.runtime_Semacquire(0xc42007f0bc)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/sema.go:47 +0x34
sync.(*WaitGroup).Wait(0xc42007f0b0)
/usr/local/Cellar/go/1.8.3/libexec/src/sync/waitgroup.go:131 +0x7a
github.com/facebookgo/grace/gracehttp.(*app).wait(0xc420078230)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:88 +0x115
github.com/facebookgo/grace/gracehttp.(*app).run.func1(0xc42007cba0, 0xc420078230)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:162 +0x51
created by github.com/facebookgo/grace/gracehttp.(*app).run
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:163 +0x1e1
goroutine 28 [chan receive]:
github.com/facebookgo/grace/gracehttp.(*app).signalHandler(0xc420078230, 0xc42007f0b0)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:106 +0x127
created by github.com/facebookgo/grace/gracehttp.(*app).wait
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:79 +0x81
goroutine 29 [chan receive]:
github.com/facebookgo/httpdown.(*server).Wait(0xc4200bc4d0, 0x12c2c80, 0xc42007f0b0)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:283 +0x5b
github.com/facebookgo/grace/gracehttp.(*app).wait.func1(0xc42007f0b0, 0xc420078230, 0x13cc280, 0xc4200bc4d0)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:83 +0x5b
created by github.com/facebookgo/grace/gracehttp.(*app).wait
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:86 +0xdc
goroutine 30 [chan receive]:
github.com/facebookgo/httpdown.(*server).Wait(0xc4200bc580, 0x12c2c80, 0xc42007f0b0)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:283 +0x5b
github.com/facebookgo/grace/gracehttp.(*app).wait.func1(0xc42007f0b0, 0xc420078230, 0x13cc280, 0xc4200bc580)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:83 +0x5b
created by github.com/facebookgo/grace/gracehttp.(*app).wait
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:86 +0xdc
goroutine 34 [select, locked to thread]:
runtime.gopark(0x12c2bc0, 0x0, 0x12b3268, 0x6, 0x18, 0x2)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/proc.go:271 +0x13a
runtime.selectgoImpl(0xc420132f50, 0x0, 0x18)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/select.go:423 +0x1364
runtime.selectgo(0xc420132f50)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/select.go:238 +0x1c
runtime.ensureSigM.func1()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/signal_unix.go:434 +0x265
runtime.goexit()
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/asm_amd64.s:2197 +0x1
goroutine 31 [chan receive]:
github.com/facebookgo/httpdown.(*server).Wait(0xc4200bc630, 0x12c2c80, 0xc42007f0b0)
/Users/sheerun/go/src/github.com/facebookgo/httpdown/httpdown.go:283 +0x5b
github.com/facebookgo/grace/gracehttp.(*app).wait.func1(0xc42007f0b0, 0xc420078230, 0x13cc280, 0xc4200bc630)
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:83 +0x5b
created by github.com/facebookgo/grace/gracehttp.(*app).wait
/Users/sheerun/go/src/github.com/facebookgo/grace/gracehttp/http.go:86 +0xdc
goroutine 50 [sleep]:
time.Sleep(0x4a817c800)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/time.go:59 +0xf9
main.newHandler.func1(0x13cdf80, 0xc420156000, 0xc42014e000)
/Users/sheerun/go/src/github.com/sheerun/demo/main.go:39 +0xf6
net/http.HandlerFunc.ServeHTTP(0xc4200e2400, 0x13cdf80, 0xc420156000, 0xc42014e000)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:1942 +0x44
net/http.(*ServeMux).ServeHTTP(0xc420084c90, 0x13cdf80, 0xc420156000, 0xc42014e000)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2238 +0x130
net/http.serverHandler.ServeHTTP(0xc4200bc2c0, 0x13cdf80, 0xc420156000, 0xc42014e000)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2568 +0x92
net/http.(*conn).serve(0xc420140000, 0x13ce400, 0xc420138080)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:1825 +0x612
created by net/http.(*Server).Serve
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:2668 +0x2ce
goroutine 51 [IO wait]:
net.runtime_pollWait(0x1618df8, 0x72, 0x7)
/usr/local/Cellar/go/1.8.3/libexec/src/runtime/netpoll.go:164 +0x59
net.(*pollDesc).wait(0xc42013a068, 0x72, 0x13cb7c0, 0x13c8428)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:75 +0x38
net.(*pollDesc).waitRead(0xc42013a068, 0xc4201380d1, 0x1)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_poll_runtime.go:80 +0x34
net.(*netFD).Read(0xc42013a000, 0xc4201380d1, 0x1, 0x1, 0x0, 0x13cb7c0, 0x13c8428)
/usr/local/Cellar/go/1.8.3/libexec/src/net/fd_unix.go:250 +0x1b7
net.(*conn).Read(0xc42013e000, 0xc4201380d1, 0x1, 0x1, 0x0, 0x0, 0x0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/net.go:181 +0x70
net/http.(*connReader).backgroundRead(0xc4201380c0)
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:656 +0x58
created by net/http.(*connReader).startBackgroundRead
/usr/local/Cellar/go/1.8.3/libexec/src/net/http/server.go:652 +0xdf
rax 0xe
rbx 0x13
rcx 0x7fff5fbfe528
rdx 0x3b9ac413
rdi 0xe03
rsi 0x13
rbp 0x7fff5fbfe560
rsp 0x7fff5fbfe528
r8 0xc420001860
r9 0x1c9
r10 0xa30261364
r11 0x202
r12 0x539da43c93d68
r13 0x54f42816f8ac0
r14 0x14c2cc2a3b89b800
r15 0xf3
rip 0x1056f03
rflags 0x202
cs 0x7
fs 0x0
gs 0x0