From patchwork Wed Sep 16 12:53:20 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Schwab X-Patchwork-Id: 518418 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 643D01400A0 for ; Wed, 16 Sep 2015 22:53:32 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b=LqEYBXng; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type; q=dns; s=default; b=D+STPOa3Q7rcjbnOjb6gc4WunOqOU agLJqjnkzhrB217PPy4Rn1xxV92cRQRDr7fxvCRHSDQLQQFEeGu/7HedJXVHvOMJ 2oFMu215USMGOyIaIwcXSBod3X++81MlChv4cjKYh88SiMd3Ws/5rKw93L9zNKX/ 7/3aN69cuNdLpw= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type; s=default; bh=TAzRBQDHep5WcRHm8tUq3w3Yh5o=; b=LqE YBXngjAX4EXVC4/Ecbf60zrZ6GVjDCqFY0CGOmKmgSZQFU6CF96aiEpGa4T+ayVA jF0p9edE8O/27iw/a3BzRIM2zWu5wOW+KCOy/K1E+xxOUtsHme6yiMpzaRl/5aqo KheNajthslblVMawZAHI/ooralgkbV4kRHCrgIHM= Received: (qmail 94994 invoked by alias); 16 Sep 2015 12:53:25 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 94958 invoked by uid 89); 16 Sep 2015 12:53:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL, BAYES_50, SPF_PASS, T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mx2.suse.de From: Andreas Schwab To: libc-alpha@sourceware.org Subject: [PATCH] Remove extra va_start/va_end calls (bug 17244) X-Yow: I once decorated my apartment entirely in ten foot salad forks!! Date: Wed, 16 Sep 2015 14:53:20 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) MIME-Version: 1.0 The extra calls are effectively no-ops in gcc, so it doesn't affect the generated code at all. Installed as obvious. Andreas. [BZ #17244] * sysdeps/unix/sysv/linux/semctl.c (__old_semctl, __new_semctl): Remove extra va_start/va_end calls. diff --git a/sysdeps/unix/sysv/linux/semctl.c b/sysdeps/unix/sysv/linux/semctl.c index e794a58..81a33a9 100644 --- a/sysdeps/unix/sysv/linux/semctl.c +++ b/sysdeps/unix/sysv/linux/semctl.c @@ -65,8 +65,6 @@ __old_semctl (int semid, int semnum, int cmd, ...) union semun arg; va_list ap; - va_start (ap, cmd); - /* Get the argument only if required. */ arg.buf = NULL; switch (cmd) @@ -85,8 +83,6 @@ __old_semctl (int semid, int semnum, int cmd, ...) break; } - va_end (ap); - return INLINE_SYSCALL (ipc, 5, IPCOP_semctl, semid, semnum, cmd, &arg); } @@ -99,8 +95,6 @@ __new_semctl (int semid, int semnum, int cmd, ...) union semun arg; va_list ap; - va_start (ap, cmd); - /* Get the argument only if required. */ arg.buf = NULL; switch (cmd) @@ -119,8 +113,6 @@ __new_semctl (int semid, int semnum, int cmd, ...) break; } - va_end (ap); - return INLINE_SYSCALL (ipc, 5, IPCOP_semctl, semid, semnum, cmd | __IPC_64, &arg); }