From c8e4f9bd080d928b10843953e172d7fb2630073f Mon Sep 17 00:00:00 2001 From: Adrian Danis Date: Tue, 28 Jul 2015 15:22:00 +1000 Subject: [PATCH] Correctly generate a 64-bit type in unmarshalling code in syscall_stub_gen This was introduced in changeset e653f8f65a916c1babe38a13d1f29e5dfb67390d where hard coded size types were replaced with an indirection. This corrects a case where a 'uint64_t' was replaced with a '%s', but there is no corresponding 'TYPES[64]' in the argument list, resulting in too few arguments when processing the string --- libsel4/tools/syscall_stub_gen.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libsel4/tools/syscall_stub_gen.py b/libsel4/tools/syscall_stub_gen.py index e50784673..812d85f1d 100644 --- a/libsel4/tools/syscall_stub_gen.py +++ b/libsel4/tools/syscall_stub_gen.py @@ -584,7 +584,7 @@ def generate_stub(arch, interface_name, method_name, method_id, input_params, ou result.append("\t%s->%s = %s;" % (param.name, members[i], words[i] % source_words)) else: if param.type.double_word: - result.append("\tresult.%s = ((%s)%s + ((%s)%s << 32));" % (TYPES[64], param.name, words[0] % source_words, words[1] % source_words)) + result.append("\tresult.%s = ((%s)%s + ((%s)%s << 32));" % (param.name, TYPES[64], words[0] % source_words, TYPES[64], words[1] % source_words)) else: for word in words: result.append("\tresult.%s = %s;" % (param.name, word % source_words))