From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:54623) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtJZt-0002AC-0f for qemu-devel@nongnu.org; Fri, 03 Feb 2012 08:53:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RtJZl-0006Po-8m for qemu-devel@nongnu.org; Fri, 03 Feb 2012 08:53:24 -0500 Received: from mnementh.archaic.org.uk ([81.2.115.146]:56497) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RtJZl-0006Ow-0X for qemu-devel@nongnu.org; Fri, 03 Feb 2012 08:53:17 -0500 From: Peter Maydell Date: Fri, 3 Feb 2012 13:53:05 +0000 Message-Id: <1328277186-21665-2-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1328277186-21665-1-git-send-email-peter.maydell@linaro.org> References: <1328277186-21665-1-git-send-email-peter.maydell@linaro.org> Subject: [Qemu-devel] [PATCH 1/2] linux-user/syscall.c: Fix indentation in prctl handling List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Riku Voipio , patches@linaro.org Clean up the odd indentation of this switch statement before we double its size by adding new cases to it. Signed-off-by: Peter Maydell --- linux-user/syscall.c | 29 +++++++++++++++-------------- 1 files changed, 15 insertions(+), 14 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 2bf9e7e..7851fb5 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -6842,21 +6842,22 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1, goto unimplemented; #endif case TARGET_NR_prctl: - switch (arg1) - { - case PR_GET_PDEATHSIG: - { - int deathsig; - ret = get_errno(prctl(arg1, &deathsig, arg3, arg4, arg5)); - if (!is_error(ret) && arg2 - && put_user_ual(deathsig, arg2)) - goto efault; - } - break; - default: - ret = get_errno(prctl(arg1, arg2, arg3, arg4, arg5)); - break; + switch (arg1) { + case PR_GET_PDEATHSIG: + { + int deathsig; + ret = get_errno(prctl(arg1, &deathsig, arg3, arg4, arg5)); + if (!is_error(ret) && arg2 + && put_user_ual(deathsig, arg2)) { + goto efault; } + break; + } + default: + /* Most prctl options have no pointer arguments */ + ret = get_errno(prctl(arg1, arg2, arg3, arg4, arg5)); + break; + } break; #ifdef TARGET_NR_arch_prctl case TARGET_NR_arch_prctl: -- 1.7.1