Skip to content

Commit

Permalink
fix(ble): fix crash on unknow multiaddr
Browse files Browse the repository at this point in the history
Signed-off-by: Sacha Froment <sfroment42@gmail.com>
  • Loading branch information
sfroment committed Nov 9, 2018
1 parent 5d49616 commit b5987a9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions core/network/ble/darwin.go
Expand Up @@ -74,6 +74,8 @@ func (b *Conn) Write(p []byte) (n int, err error) {
val, err := b.rAddr.ValueForProtocol(PBle)
if err != nil {
return 0, err
} else if val == "" {
return 0, fmt.Errorf("ble can't dial unknow multiaddr")
}

ma := C.CString(val)
Expand Down

0 comments on commit b5987a9

Please sign in to comment.