From 92ee8e9f76e95db303abc16016834ec1330bb15c Mon Sep 17 00:00:00 2001 From: Slawek Kaplonski Date: Thu, 23 Apr 2020 11:11:04 +0200 Subject: [PATCH] Fix is_port_bound function in l3_dvr_db module This function was added recently by [1] but during cherry-picking it from Rocky I made mistake in "if" condition which was different in Queens than in newer versions. This patch fixes this mistake. It is needed only for Queens release. [1] https://review.opendev.org/#/c/717321/ Change-Id: Iad5212edb659db0d31569c980ba8e7106637f65b --- neutron/db/l3_dvr_db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neutron/db/l3_dvr_db.py b/neutron/db/l3_dvr_db.py index ee699cdcd5d..634367dd6c4 100644 --- a/neutron/db/l3_dvr_db.py +++ b/neutron/db/l3_dvr_db.py @@ -59,7 +59,7 @@ l3_dvr_db.register_db_l3_dvr_opts() # TODO(slaweq): this should be moved to neutron_lib.plugins.utils module def is_port_bound(port): - if port.port_binding: + if not port.port_binding: LOG.warning("Binding for port %s was not found.", port) return False return port.port_binding[portbindings_extended.VIF_TYPE] not in [