X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvpp-api%2Fvapi%2Fvapi_json_parser.py;fp=src%2Fvpp-api%2Fvapi%2Fvapi_json_parser.py;h=d7669365ce87e7a3fdc17994dd829fcb87a81ea3;hb=e5ff5a36dd126ee57dca4e0b03da2f7704e0a4f5;hp=a9d2c8186bc30c2e9985c89375e1e97426ff3a7d;hpb=b6fde4a8bae474c6b73d08d223028f42e396d452;p=vpp.git diff --git a/src/vpp-api/vapi/vapi_json_parser.py b/src/vpp-api/vapi/vapi_json_parser.py index a9d2c8186bc..d7669365ce8 100644 --- a/src/vpp-api/vapi/vapi_json_parser.py +++ b/src/vpp-api/vapi/vapi_json_parser.py @@ -177,12 +177,15 @@ class Message(object): p = field_class(field_name=field[1], field_type=field_type) elif l == 3: - if field[2] == 0: + if field[2] == 0 and field[0] != 'string': raise ParseError( "While parsing message `%s': variable length " "array `%s' doesn't have reference to member " "containing the actual length" % ( name, field[1])) + if field[0] == 'string' and field[2] > 0: + field_type = json_parser.lookup_type_like_id('u8') + p = field_class( field_name=field[1], field_type=field_type,