ref: 31c60100dbd786b407a078d891bf52a174ef6ad0
parent: a9a1e79a8b4fa0fc1a1b51926650b197ad61ff4c
author: Paul Brossier <piem@piem.org>
date: Fri Aug 26 21:51:45 EDT 2016
python/lib/gen_code.py: fix number of output
--- a/python/lib/gen_code.py
+++ b/python/lib/gen_code.py
@@ -426,7 +426,7 @@
)
if len(self.do_outputs) > 1:
out += """
- outputs = PyTuple_New(2);""".format(len(self.do_outputs))
+ outputs = PyTuple_New({:d});""".format(len(self.do_outputs))
for i, p in enumerate(self.do_outputs):
out += """
PyTuple_SetItem( outputs, {i}, self->{p[name]});""".format(i = i, p = p)