Skip to content
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

nil dereference in scw rename #289

Closed
moul opened this issue Feb 29, 2016 · 0 comments
Closed

nil dereference in scw rename #289

moul opened this issue Feb 29, 2016 · 0 comments
Assignees

Comments

@moul
Copy link
Contributor

moul commented Feb 29, 2016

➜  ~  scw -D rename desperate-boyd test
DEBU[0000] curl -X PATCH -d "{\"name\":\"test\"}" -H "Content-Type: application/json" -H "User-Agent: scw/v1.7.1+dev" -H "X-Auth-Token: 00000000-0000-1000-0000-000000000000" https://api.scaleway.com/servers/11111111-1111-1111-1111-111111111111
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x10c02c]

goroutine 1 [running]:
github.com/scaleway/scaleway-cli/pkg/commands.RunRename(0x8a06e0, 0xc82002c008, 0x8a01c0, 0xc82002c010, 0x8a01c0, 0xc82002c018, 0xc820097000, 0x3a, 0x3a, 0xc82000a120, ...)
    /Users/moul/go/src/github.com/scaleway/scaleway-cli/pkg/commands/rename.go:32 +0x2bc
github.com/scaleway/scaleway-cli/pkg/cli.runRename(0x75b680, 0xc82000a120, 0x2, 0x2, 0x0, 0x0)
    /Users/moul/go/src/github.com/scaleway/scaleway-cli/pkg/cli/cmd_rename.go:36 +0x19b
github.com/scaleway/scaleway-cli/pkg/cli.Start(0xc82000a100, 0x4, 0x4, 0xc8200d9140, 0x0, 0x0, 0x0)
    /Users/moul/go/src/github.com/scaleway/scaleway-cli/pkg/cli/main.go:127 +0xcf5
main.main()
    /Users/moul/go/src/github.com/scaleway/scaleway-cli/cmd/scw/main.go:19 +0x8e

goroutine 17 [syscall, locked to thread]:
runtime.goexit()
    /usr/local/Cellar/go/1.5.3/libexec/src/runtime/asm_amd64.s:1721 +0x1

goroutine 5 [syscall]:
os/signal.loop()
    /usr/local/Cellar/go/1.5.3/libexec/src/os/signal/signal_unix.go:22 +0x18
created by os/signal.init.1
    /usr/local/Cellar/go/1.5.3/libexec/src/os/signal/signal_unix.go:28 +0x37

goroutine 15 [IO wait]:
net.runtime_pollWait(0x8a20f0, 0x72, 0xc820012200)
    /usr/local/Cellar/go/1.5.3/libexec/src/runtime/netpoll.go:157 +0x60
net.(*pollDesc).Wait(0xc82017a530, 0x72, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/fd_poll_runtime.go:73 +0x3a
net.(*pollDesc).WaitRead(0xc82017a530, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/fd_poll_runtime.go:78 +0x36
net.(*netFD).Read(0xc82017a4d0, 0xc8200c0000, 0x1000, 0x1000, 0x0, 0x89c050, 0xc820012200)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/fd_unix.go:232 +0x23a
net.(*conn).Read(0xc82002c3a8, 0xc8200c0000, 0x1000, 0x1000, 0x0, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/net.go:172 +0xe4
crypto/tls.(*block).readFromUntil(0xc820147a10, 0x8a21b0, 0xc82002c3a8, 0x5, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/crypto/tls/conn.go:455 +0xcc
crypto/tls.(*Conn).readRecord(0xc82013b080, 0x5d6317, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/crypto/tls/conn.go:540 +0x2d1
crypto/tls.(*Conn).Read(0xc82013b080, 0xc82019d000, 0x1000, 0x1000, 0x0, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/crypto/tls/conn.go:901 +0x167
net/http.noteEOFReader.Read(0x8afef0, 0xc82013b080, 0xc8200143c8, 0xc82019d000, 0x1000, 0x1000, 0x0, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/http/transport.go:1370 +0x67
net/http.(*noteEOFReader).Read(0xc82030e180, 0xc82019d000, 0x1000, 0x1000, 0x0, 0x0, 0x0)
    <autogenerated>:126 +0xd0
bufio.(*Reader).fill(0xc82029e4e0)
    /usr/local/Cellar/go/1.5.3/libexec/src/bufio/bufio.go:97 +0x1e9
bufio.(*Reader).Peek(0xc82029e4e0, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0)
    /usr/local/Cellar/go/1.5.3/libexec/src/bufio/bufio.go:132 +0xcc
net/http.(*persistConn).readLoop(0xc820014370)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/http/transport.go:876 +0xf7
created by net/http.(*Transport).dialConn
    /usr/local/Cellar/go/1.5.3/libexec/src/net/http/transport.go:685 +0xc78

goroutine 16 [select]:
net/http.(*persistConn).writeLoop(0xc820014370)
    /usr/local/Cellar/go/1.5.3/libexec/src/net/http/transport.go:1009 +0x40c
created by net/http.(*Transport).dialConn
    /usr/local/Cellar/go/1.5.3/libexec/src/net/http/transport.go:686 +0xc9d
@moul moul added the bug label Feb 29, 2016
@moul moul closed this as completed Feb 29, 2016
@moul moul removed the bug label Feb 29, 2016
clement-gilbert pushed a commit to clement-gilbert/scaleway-cli that referenced this issue Mar 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants