mirror of
https://github.com/evilsocket/opensnitch.git
synced 2025-03-04 00:24:40 +01:00
fixed leak serializing rules' operator
mainly when connecting by the first time to the GUI, and at the same time asking to allow/deny a connection.
This commit is contained in:
parent
250dcb1f6d
commit
9efaa37098
1 changed files with 3 additions and 0 deletions
|
@ -127,6 +127,9 @@ func (r *Rule) Serialize() *protocol.Rule {
|
|||
if r == nil {
|
||||
return nil
|
||||
}
|
||||
r.Operator.Lock()
|
||||
defer r.Operator.Unlock()
|
||||
|
||||
protoRule := &protocol.Rule{
|
||||
Created: r.Created.Unix(),
|
||||
Name: string(r.Name),
|
||||
|
|
Loading…
Add table
Reference in a new issue