]> git.proxmox.com Git - ovs.git/commit
ovsdb-idlc.in: fix dict change during iteration.
authorFlavio Leitner <fbl@sysclose.org>
Sat, 14 Sep 2019 23:17:28 +0000 (20:17 -0300)
committerBen Pfaff <blp@ovn.org>
Tue, 24 Sep 2019 20:05:52 +0000 (13:05 -0700)
commitd84109f0b60096ce71cd0537b31b69a7f5ea8756
tree41cd2340e4e9ab439d967a581b034310759faa39
parenta0b89c5139aba1e4ea1fa1bf79c69b4b20cc492f
ovsdb-idlc.in: fix dict change during iteration.

Python3 complains if a dict key is changed during the
iteration.

Use list() to create a copy of it.

Traceback (most recent call last):
  File "./ovsdb/ovsdb-idlc.in", line 1581, in <module>
    func(*args[1:])
  File "./ovsdb/ovsdb-idlc.in", line 185, in printCIDLHeader
    replace_cplusplus_keyword(schema)
  File "./ovsdb/ovsdb-idlc.in", line 179, in replace_cplusplus_keyword
    for columnName in table.columns:
RuntimeError: dictionary keys changed during iteration

Signed-off-by: Flavio Leitner <fbl@sysclose.org>
Signed-off-by: Ben Pfaff <blp@ovn.org>
ovsdb/ovsdb-idlc.in