From b0deafc641be0051c09be13c4454be6fde4cae3c Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 31 Mar 2025 09:54:02 +1000 Subject: [PATCH] scanner: convert the 'version' and 'since' arguments to int Part-of: --- proto/ei-scanner | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/proto/ei-scanner b/proto/ei-scanner index d23fea7..af30558 100755 --- a/proto/ei-scanner +++ b/proto/ei-scanner @@ -520,7 +520,7 @@ class ProtocolParser(xml.sax.handler.ContentHandler): try: name = attrs["name"] - version = attrs["version"] + version = int(attrs["version"]) except KeyError as e: raise XmlError.create( f"Missing attribute {e} in element '{element}'", @@ -559,7 +559,7 @@ class ProtocolParser(xml.sax.handler.ContentHandler): ) try: name = attrs["name"] - since = attrs["since"] + since = int(attrs["since"]) except KeyError as e: raise XmlError.create( f"Missing attribute {e} in element '{element}'", @@ -612,7 +612,7 @@ class ProtocolParser(xml.sax.handler.ContentHandler): try: name = attrs["name"] - since = attrs["since"] + since = int(attrs["since"]) except KeyError as e: raise XmlError.create( f"Missing attribute {e} in element '{element}'", @@ -646,7 +646,7 @@ class ProtocolParser(xml.sax.handler.ContentHandler): ) try: name = attrs["name"] - since = attrs["since"] + since = int(attrs["since"]) except KeyError as e: raise XmlError.create( f"Missing attribute {e} in element '{element}'",