aboutsummaryrefslogtreecommitdiffstats
path: root/build-aux
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2014-10-08 11:06:02 +0200
committerAleksander Morgado <aleksander@aleksander.es>2014-10-08 11:06:26 +0200
commit150768f6bba84182e7d3a956c36d5a7d27129759 (patch)
tree8da4f7f70dbe098209ae74afa31cf6bbb18b2cee /build-aux
parentb439d6d13ec8a8e4ff247b7d042424f10574aa84 (diff)
downloadexternal_libqmi-150768f6bba84182e7d3a956c36d5a7d27129759.zip
external_libqmi-150768f6bba84182e7d3a956c36d5a7d27129759.tar.gz
external_libqmi-150768f6bba84182e7d3a956c36d5a7d27129759.tar.bz2
qmi-codegen: error out if invalid array size element in JSON
Suggested by Thomas Haller <thaller@redhat.com>.
Diffstat (limited to 'build-aux')
-rw-r--r--build-aux/qmi-codegen/VariableArray.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/build-aux/qmi-codegen/VariableArray.py b/build-aux/qmi-codegen/VariableArray.py
index 6af3c2d..793bbc1 100644
--- a/build-aux/qmi-codegen/VariableArray.py
+++ b/build-aux/qmi-codegen/VariableArray.py
@@ -246,7 +246,7 @@ class VariableArray(Variable):
elif self.array_size_element.public_format == 'guint32':
translations['array_size_element_size'] = '4'
else:
- translations['array_size_element_size'] = '0'
+ raise ValueError('Invalid array size element format in %s array' % (self.name))
template = (
'${lp} ${array_size_element_format} ${common_var_prefix}_n_items;\n'