Fix state transition thinko 07/101407/1
authorRobert Varga <robert.varga@pantheon.tech>
Tue, 31 May 2022 18:37:29 +0000 (20:37 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Wed, 1 Jun 2022 13:40:03 +0000 (15:40 +0200)
commit5401b70a0284c4bdc54b1b9311eb08d91fdb7d41
tree9627f9a57cb79653bc1de281329aa7fc0e02f82f
parent316c3b56656420d6cd6ff58c024ff6f671a038cc
Fix state transition thinko

The future returned from reconnect strategy may have completed before
we add a listener. Make sure we record the future before adding the
listener.

Also change checkState() to a verify() with a proper identity check
to work with nulls and a proper message.

JIRA: NETCONF-827
Change-Id: Ica152cd1445e797c122e542aa1138232f11c6736
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 5e9f3517718f4475c3026acba0a5afb6f19388fa)
netconf/netconf-netty-util/src/main/java/org/opendaylight/netconf/nettyutil/NetconfSessionPromise.java