diff options
Diffstat (limited to 'libc/tools/gensyscalls.py')
-rwxr-xr-x | libc/tools/gensyscalls.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libc/tools/gensyscalls.py b/libc/tools/gensyscalls.py index d8d43029f..baaa52d25 100755 --- a/libc/tools/gensyscalls.py +++ b/libc/tools/gensyscalls.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # This tool is used to generate the assembler system call stubs, # the header files listing all available system calls, and the @@ -434,13 +434,13 @@ def main(arch, syscall_file): for syscall in parser.syscalls: syscall["__NR_name"] = make__NR_name(syscall["name"]) - if syscall.has_key("arm"): + if "arm" in syscall: syscall["asm-arm"] = add_footer(32, arm_eabi_genstub(syscall), syscall) - if syscall.has_key("arm64"): + if "arm64" in syscall: syscall["asm-arm64"] = add_footer(64, arm64_genstub(syscall), syscall) - if syscall.has_key("x86"): + if "x86" in syscall: if syscall["socketcall_id"] >= 0: syscall["asm-x86"] = add_footer(32, x86_genstub_socketcall(syscall), syscall) else: @@ -449,13 +449,13 @@ def main(arch, syscall_file): E("socketcall_id for dispatch syscalls is only supported for x86 in '%s'" % t) return - if syscall.has_key("x86_64"): + if "x86_64" in syscall: syscall["asm-x86_64"] = add_footer(64, x86_64_genstub(syscall), syscall) print("/* Generated by gensyscalls.py. Do not edit. */\n") print("#include <private/bionic_asm.h>\n") for syscall in parser.syscalls: - if syscall.has_key("asm-%s" % arch): + if ("asm-%s" % arch) in syscall: print(syscall["asm-%s" % arch]) if arch == 'arm64': |