From patchwork Mon Jul 30 16:04:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Blue Swirl X-Patchwork-Id: 174034 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 776722C00C9 for ; Tue, 31 Jul 2012 02:04:40 +1000 (EST) Received: from localhost ([::1]:52180 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SvsST-0001yy-5y for incoming@patchwork.ozlabs.org; Mon, 30 Jul 2012 12:04:37 -0400 Received: from eggs.gnu.org ([208.118.235.92]:33464) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SvsSC-0001tY-OI for qemu-devel@nongnu.org; Mon, 30 Jul 2012 12:04:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SvsS1-0000WO-8S for qemu-devel@nongnu.org; Mon, 30 Jul 2012 12:04:20 -0400 Received: from mail-ey0-f173.google.com ([209.85.215.173]:37322) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SvsS1-0000VE-0n for qemu-devel@nongnu.org; Mon, 30 Jul 2012 12:04:09 -0400 Received: by mail-ey0-f173.google.com with SMTP id h1so1159281eaa.4 for ; Mon, 30 Jul 2012 09:04:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :in-reply-to:references; bh=CwYjtNoxcE3y2a/IG3sFw3MaX/lRYaa4dX97i9+V4oQ=; b=vcVEBYXx6PZ9hyEJxgnlggxx/sWdGNrbfUGMq6U3kx/dL4456ycyZaVcCQ6PqZHHmn dK0Ka4H4ubCNPypqB71Qg16OT0t7Czgp4p/ZMJmNcEHURYt1yw4yM2ccbYUFHw/H4d11 s+9JPUmiavYNFswR+gDZUEcjk4sK9fqYKdKUEHAHnBi/4q+np7kOE8CnPMADlwwj3vRH xDRfx5I4Sv2ImNE8PV8E9aGKInpfAkscsX1CrSfcvtqQ8232AQw5AxA9bJCx2AKyrExB b0Y9L3xB2t42fj+OEupx4ivCpET3NF3Igjl+YHLtmf9bwAojBJqCCEjuDajEkkKTFWhY cJ1Q== Received: by 10.14.175.5 with SMTP id y5mr12611549eel.40.1343664248675; Mon, 30 Jul 2012 09:04:08 -0700 (PDT) Received: from localhost.localdomain (blueswirl.broker.freenet6.net. [2001:5c0:1400:b::d5a3]) by mx.google.com with ESMTPS id k41sm6346971eep.13.2012.07.30.09.04.06 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 30 Jul 2012 09:04:07 -0700 (PDT) From: blauwirbel@gmail.com To: qemu-devel@nongnu.org Date: Mon, 30 Jul 2012 16:04:32 +0000 Message-Id: <5ddedba0015c15117770b3d1860f7dd6d8d08a0c.1343664167.git.blauwirbel@gmail.com> X-Mailer: git-send-email 1.7.2.5 In-Reply-To: References: In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.215.173 Cc: blauwirbel@gmail.com Subject: [Qemu-devel] [PATCH 2/5] sparc: fix expression with uninitialized initial value X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Blue Swirl err was uninitalized, it's not OK to use |=. Spotted by Clang compiler. Fix by replacing |= by =. Signed-off-by: Blue Swirl Reviewed-by: Peter Maydell --- linux-user/signal.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/linux-user/signal.c b/linux-user/signal.c index 97f30d9..3d6b5df 100644 --- a/linux-user/signal.c +++ b/linux-user/signal.c @@ -2061,7 +2061,7 @@ restore_fpu_state(CPUSPARCState *env, qemu_siginfo_fpu_t *fpu) err = __copy_from_user(&env->fpr[0], &fpu->si_float_regs[0], (sizeof(unsigned long) * 32)); #endif - err |= __get_user(env->fsr, &fpu->si_fsr); + err = __get_user(env->fsr, &fpu->si_fsr); #if 0 err |= __get_user(current->thread.fpqdepth, &fpu->si_fpqdepth); if (current->thread.fpqdepth != 0)