panic #7
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The code from the example/client/ folder does not work.
First I start the server, then the client:
go run ./... localhost:6900 "" "" and getting it
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x51a147]
goroutine 1 [running]:
github.com/unistack-org/go-rfb.(*DefaultClientSecurityHandler).Handle(0x6c4180, 0x5a9b20, 0xc00006a500, 0x0, 0x0)
/home/marlik/go/pkg/mod/github.com/unistack-org/go-rfb@v0.0.0-20200122230427-c00b8c7ae0e7/handlers.go:149 +0x417
github.com/unistack-org/go-rfb.Connect(0x5a87e0, 0xc00009e000, 0x5a9740, 0xc000010010, 0xc000068000, 0x0, 0xc000010010, 0x0)
/home/marlik/go/pkg/mod/github.com/unistack-org/go-rfb@v0.0.0-20200122230427-c00b8c7ae0e7/client.go:37 +0x117
main.main()
/home/marlik/go/src/clientVNC/main.go:40 +0x46d
exit status 2
It seems to me to pass command line arguments through flags, a good idea.
Thanks I'll look at this
please, provide full example of main.go
looks like you pass nil net.Conn to Connect func
i'm add check for nil net.Conn in Connect func
cc.Wait()
Unreachable code
Inspection info: Reports code that can never be executed because there exists no control flow path to the code from the rest of the program.
client.go
yes, i'm fix it now, please wait
please check the gist: https://gist.github.com/110bb281e332a83d65b2318b6cf8c9b2
simply worker loop must be before vnc.Connect, other fixes in master branch of go-rfb (please use latest master)
Works! Thank.