Skip to content

Commit c27b1cb

Browse files
Linus Wallgrendeadprogram
authored andcommitted
Document async Disconnect behaviour
This was mentioned by @aykevl in #32 (comment)
1 parent 2fb3b08 commit c27b1cb

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

gap_darwin.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,8 @@ func (a *Adapter) Connect(address Addresser, params ConnectionParams) (*Device,
128128
}
129129
}
130130

131-
// Disconnect from the BLE device.
131+
// Disconnect from the BLE device. This method is non-blocking and does not
132+
// wait until the connection is fully gone.
132133
func (d *Device) Disconnect() error {
133134
d.cm.CancelConnect(d.prph)
134135
return nil

gap_linux.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,8 @@ func (a *Adapter) Connect(address Addresser, params ConnectionParams) (*Device,
267267
}, nil
268268
}
269269

270-
// Disconnect from the BLE device.
270+
// Disconnect from the BLE device. This method is non-blocking and does not
271+
// wait until the connection is fully gone.
271272
func (d *Device) Disconnect() error {
272273
return d.device.Disconnect()
273274
}

0 commit comments

Comments
 (0)