コード例 #1
0
ファイル: usb.go プロジェクト: hanwen/usb
// Decrement the reference count of a device.
func (d *Device) Unref() {
	C.libusb_unref_device((*C.libusb_device)(d.me()))
}
コード例 #2
0
ファイル: usb.go プロジェクト: thequux/gousb
func (dev *Device) destroy() {
	C.libusb_unref_device(dev.device)
	dev.device = nil
	dev.ctx = nil
}