summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorSatoshi Kobayashi <satoshi-k@stratosphere.co.jp>2014-03-13 07:04:50 +0000
committerFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2014-03-16 20:38:32 +0900
commit8fd3959d0680db272a040e0fe8c0a8a31f457518 (patch)
treec48c0e0a7c38f99f7249c509614874ffaafbb6ce
parenteb07d4bf81a72a42b7f9e4aea0356f8ba8023f38 (diff)
ofctl_v1_3: Fix unsuitable log
ofproto_v1_3.OFPGT_ALL is 0 and 0 is False on Python. When using type 'ALL', the following is set to True. if not type_: LOG.debug('Unknown type: %s', group.get('type')) Therefore, the log unsuitable is outputted: Unknown type: ALL Signed-off-by: Satoshi Kobayashi <satoshi-k@stratosphere.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
-rw-r--r--ryu/lib/ofctl_v1_3.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ryu/lib/ofctl_v1_3.py b/ryu/lib/ofctl_v1_3.py
index 403c82e2..1f0fd30a 100644
--- a/ryu/lib/ofctl_v1_3.py
+++ b/ryu/lib/ofctl_v1_3.py
@@ -863,7 +863,7 @@ def mod_group_entry(dp, group, cmd):
'FF': dp.ofproto.OFPGT_FF}
type_ = type_convert.get(group.get('type'))
- if not type_:
+ if type_ is None:
LOG.debug('Unknown type: %s', group.get('type'))
group_id = int(group.get('group_id', 0))