From patchwork Sat Jan 27 15:56:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 866743 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-89700-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="H1BIzPut"; dkim-atps=neutral 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 3zTL571S0dz9sBd for ; Sun, 28 Jan 2018 02:57:30 +1100 (AEDT) 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:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=HgTIrlT4R0XpSrRa39adqZnnzsbZKPk LGhjVkR1uQ380PAmFCeo0zTjckbpn2MS6chbxwyLxpaXlj5HMkNAr1E0obvpspLr lQ2KvCaMwx942LhLcwGeogRaSzPJuJ/UNxBkRBNMf/uupyNgGQSuWBeVLaLA6Wgm tHANXf5choVc= 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:cc:subject:date:message-id:in-reply-to :references; s=default; bh=soMDCkfH0VTXR1iGzMiIAzaVvEg=; b=H1BIz PutwvFJio7KpJfxoQ99fFV2umfyW66umPg1IrnCh11rPvl2Q0tbHYb930WKLBEoD CE5hW63kEmGjoP75zbC7JLNVwBguXjP//2d/1Qk8pPkxgbkiG8KYMBk/vEskG5dp m3L+snWsn+Ot/fW+BAEL0CXogXPUcmpIy95L5M= Received: (qmail 64653 invoked by alias); 27 Jan 2018 15:56:40 -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 64497 invoked by uid 89); 27 Jan 2018 15:56:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy= X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 2/7] hurd: fix warning Date: Sat, 27 Jan 2018 16:56:24 +0100 Message-Id: <20180127155629.23644-3-samuel.thibault@ens-lyon.org> In-Reply-To: <20180127155629.23644-1-samuel.thibault@ens-lyon.org> References: <20180127155629.23644-1-samuel.thibault@ens-lyon.org> * sysdeps/mach/hurd/profil.c: Reuse `a' variable instead of introducing a `c' variable. --- ChangeLog | 2 ++ sysdeps/mach/hurd/profil.c | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index e6392de4e8..d923c6444f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,8 @@ 2018-01-27 Samuel Thibault * sysdeps/mach/hurd/xmknodat.c: Include . + * sysdeps/mach/hurd/profil.c: Reuse `a' variable instead of introducing + a `c' variable. 2018-01-27 James Clarke diff --git a/sysdeps/mach/hurd/profil.c b/sysdeps/mach/hurd/profil.c index 1323457acb..2fe8f9de56 100644 --- a/sysdeps/mach/hurd/profil.c +++ b/sysdeps/mach/hurd/profil.c @@ -154,14 +154,14 @@ fetch_samples (void) pc_samples, &nsamples); if (err) { - static error_t special_profil_failure; - static volatile int a, b, c; + static volatile error_t special_profil_failure; + static volatile int a, b; special_profil_failure = err; a = 1; b = 0; while (1) - c = a / b; + a = a / b; } for (i = 0; i < nsamples; ++i)