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: 8724 X-Patchwork-Delegate: schwab@linux-m68k.org 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); }