mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 02:36:57 -07:00
fix: added a mutex to write ops in the hid module
This commit is contained in:
parent
e0e1f4e6df
commit
d21f3b447a
4 changed files with 11 additions and 0 deletions
|
@ -81,6 +81,9 @@ func (mod *HIDRecon) prepInjection() (error, *network.HIDDevice, []*Command) {
|
|||
}
|
||||
|
||||
func (mod *HIDRecon) doInjection() {
|
||||
mod.writeLock.Lock()
|
||||
defer mod.writeLock.Unlock()
|
||||
|
||||
err, dev, cmds := mod.prepInjection()
|
||||
if err != nil {
|
||||
mod.Error("%v", err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue