diff options
author | Ben Pfaff <blp@nicira.com> | 2012-11-09 09:55:12 -0800 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2012-11-09 10:01:42 -0800 |
commit | cf7cf630e24dddba9177fcd68bcfa903689c7b72 (patch) | |
tree | f2e9e170b58ff92555bb5197fc5766a03210e262 /build-aux/extract-ofp-msgs | |
parent | 74c4b9c1c24b6579dcaa127268530af9bffa29b4 (diff) | |
download | openvswitch-cf7cf630e24dddba9177fcd68bcfa903689c7b72.tar.gz |
ofp-msgs: Accept all versions of OpenFlow "hello" messages.
Since the ofp-msgs code was introduced, only "hello" messages for versions
of OpenFlow actually understood (to some extent) by Open vSwitch could be
decoded correctly. This commit corrects that, by making every version of
OpenFlow immutable messages acceptable.
Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'build-aux/extract-ofp-msgs')
-rwxr-xr-x | build-aux/extract-ofp-msgs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/build-aux/extract-ofp-msgs b/build-aux/extract-ofp-msgs index ad1a8a832..980728975 100755 --- a/build-aux/extract-ofp-msgs +++ b/build-aux/extract-ofp-msgs @@ -29,7 +29,8 @@ version_map = {"1.0": (OFP10_VERSION, OFP10_VERSION), "1.2+": (OFP12_VERSION, OFP13_VERSION), "1.3+": (OFP13_VERSION, OFP13_VERSION), "1.0-1.1": (OFP10_VERSION, OFP11_VERSION), - "1.0-1.2": (OFP10_VERSION, OFP12_VERSION)} + "1.0-1.2": (OFP10_VERSION, OFP12_VERSION), + "<all>": (0x01, 0xff)} def get_line(): global line @@ -104,7 +105,7 @@ def extract_ofp_msgs(output_file_name): comment += ' %s' % line.lstrip('* \t').rstrip(' \t\r\n') comment = comment[:-2].rstrip() - m = re.match(r'([A-Z]+) ([-.+\d]+) \((\d+)\): ([^.]+)\.$', comment) + m = re.match(r'([A-Z]+) ([-.+\d]+|<all>) \((\d+)\): ([^.]+)\.$', comment) if not m: fatal("unexpected syntax between messages") type_, versions, number, contents = m.groups() |