From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1352 invoked by alias); 28 Jun 2016 14:21:39 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 1323 invoked by uid 89); 28 Jun 2016 14:21:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-oi0-f51.google.com Received: from mail-oi0-f51.google.com (HELO mail-oi0-f51.google.com) (209.85.218.51) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Tue, 28 Jun 2016 14:21:28 +0000 Received: by mail-oi0-f51.google.com with SMTP id s66so24657560oif.1 for ; Tue, 28 Jun 2016 07:21:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=Srm/lurL6Xpwj0Fws33ZzrJEfcDSSbWi+c7xLq7QiSA=; b=AKp8VH5RkiPtMUwl60Wnu+hO6wb5ubmZ7EljJBkNoLzOJ3Retdn3Jg4XhiyZf2XKE7 jKkYGqUpXhpCIgH3jAD41BO47aCpq6G+Umr7/R6nvOgaLy90XXCC2wU8FS2iYRyENo5y kXOfnfI2/7J+J47AXjWHgL8ddLPbRdXCLBeCBB+2s+V32ElTK5zdYhb/5j/e/0nOG07a eXK1oDbkeEYoZg05BiFMr5mxFF+Mv9l6yIiVMViB1Q6Vw/2nVuAo4BHFxXOVpeB20eLE msI2cuhWSn7eNxX/iTZYOskrhHNYkuHdgbN4lsaSaX3ByC4R/Ma/tYj+Z2vid+aUxo/y f6CQ== X-Gm-Message-State: ALyK8tIsWgKyctAIeBd9Y6WrSp4v3ElqcSvnBpwHmVsqjng8kou8OjdlhviSfNCzv0zs4k7NL0jOTEl2hvhQCg== X-Received: by 10.202.62.196 with SMTP id l187mr1905134oia.142.1467123687052; Tue, 28 Jun 2016 07:21:27 -0700 (PDT) MIME-Version: 1.0 Received: by 10.202.182.130 with HTTP; Tue, 28 Jun 2016 07:21:26 -0700 (PDT) In-Reply-To: <1465248812-23902-2-git-send-email-tom@tromey.com> References: <1465248812-23902-1-git-send-email-tom@tromey.com> <1465248812-23902-2-git-send-email-tom@tromey.com> From: Yao Qi Date: Tue, 28 Jun 2016 14:21:00 -0000 Message-ID: Subject: Re: [RFA 1/6] Change reopen_exec_file to check result of stat To: Tom Tromey Cc: "gdb-patches@sourceware.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2016-06/txt/msg00462.txt.bz2 On Mon, Jun 6, 2016 at 10:33 PM, Tom Tromey wrote: > This seems to be a real bug found by -Wunused-but-set-variable. If > "stat" fails for some reason, gdb would use the uninitialized "st". > > 2016-06-06 Tom Tromey > > * corefile.c (reopen_exec_file): Only examine st.st_mtime if stat > succeeded. Patch is good to me. --=20 Yao (=E9=BD=90=E5=B0=A7)