fix(opcua): clean client on disconnect so that connect works cleanly (#9583)

This commit is contained in:
Marcus Ilgner 2021-08-10 23:18:04 +02:00 committed by GitHub
parent dbc4e269be
commit 7def7e7328
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -507,6 +507,7 @@ func disconnect(o *OpcUA) error {
case "opc.tcp":
o.state = Disconnected
o.client.Close()
o.client = nil
return nil
default:
return fmt.Errorf("invalid controller")