From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 37669 invoked by alias); 31 Jul 2017 08:51:08 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 37647 invoked by uid 89); 31 Jul 2017 08:51:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-11.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=distance X-Spam-User: qpsmtpd, 2 recipients X-HELO: mail-lf0-f66.google.com Received: from mail-lf0-f66.google.com (HELO mail-lf0-f66.google.com) (209.85.215.66) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 31 Jul 2017 08:51:06 +0000 Received: by mail-lf0-f66.google.com with SMTP id y15so14245603lfd.5; Mon, 31 Jul 2017 01:51:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=E3fE2i+UfQveENYIHB/AuGzqD2EFNhDcRiXvlq629A0=; b=EAvrTVB3rvZDCvb958cAtfkJLP0PoluywAPjWn0GTexCQPtrXb8Lk3elE/408LRPhS xQes4CdKouyqdG662HVhbVV4R6Ev3eMVVPGvLZTG2NUj2eETAmhVCBrR/1+9SpR7YzNB GjgYr6O8tCrkzdEptC9LLlvpalGWSlkGq56i7IB12SKH8kj247Y/VjMLZiQB7k1umqhN P3kyAZae22r4W1fDdAGBkYQ0+r8XnASYbcmTM9CeEzRH0gdnob3Yb4wXWD7K7bziNua5 6pyQI3RjYGAP9AINuqomgbfFpw/92wqBuioM/QNJGhZYFh1TFTJul3TQQbH0TuKivniy BpEQ== X-Gm-Message-State: AIVw113HDhBY+0aL9okP9G5LAdXqRjbHW4e5tXqOhlhpKZoJ4Kd+SjAV 7kzT9OiU9W6yGugLWMvqWXCq6GlGxhn3 X-Received: by 10.46.80.87 with SMTP id v23mr6707670ljd.156.1501491064654; Mon, 31 Jul 2017 01:51:04 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.31.134 with HTTP; Mon, 31 Jul 2017 01:51:04 -0700 (PDT) In-Reply-To: <20170731073947.GO2123@tucnak> References: <20170731073947.GO2123@tucnak> From: Richard Biener Date: Mon, 31 Jul 2017 08:51:00 -0000 Message-ID: Subject: Re: [PATCH] Fix a pasto in gfc_check_num_images To: Jakub Jelinek Cc: "fortran@gcc.gnu.org" , GCC Patches Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2017-07/txt/msg01996.txt.bz2 On Mon, Jul 31, 2017 at 9:39 AM, Jakub Jelinek wrote: > Hi! > > bootstrap-ubsan reported taking address of a &distance->where when > distance is NULL. The function has one block guarded with if (distance) > and another guarded with if (failed), so I think this is just a pasto > from the earlier if (distance) block. > > Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? Ok. Richard. > 2017-07-31 Jakub Jelinek > > * check.c (gfc_check_num_images): Fix a pasto. > > --- gcc/fortran/check.c.jj 2017-03-05 22:39:52.000000000 +0100 > +++ gcc/fortran/check.c 2017-07-28 14:30:40.503511275 +0200 > @@ -5149,7 +5149,7 @@ gfc_check_num_images (gfc_expr *distance > return false; > > if (!gfc_notify_std (GFC_STD_F2008_TS, "FAILED= argument to " > - "NUM_IMAGES at %L", &distance->where)) > + "NUM_IMAGES at %L", &failed->where)) > return false; > } > > > Jakub