1
0
mirror of https://github.com/kidoman/embd synced 2024-06-14 06:39:52 +02:00

fixed locking when closing 1-wire bus

This commit is contained in:
Max Matveev 2016-02-06 01:03:26 -08:00
parent 4a75b30fcc
commit 6e7e0c31bd

View File

@ -180,8 +180,6 @@ func (b *w1Bus) Close() error {
} }
func (d *w1Device) Close() error { func (d *w1Device) Close() error {
d.bus.Mu.Lock()
defer d.bus.Mu.Unlock()
if !d.initialized { if !d.initialized {
return nil return nil