From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6514 invoked by alias); 17 Jun 2011 19:03:06 -0000 Received: (qmail 6496 invoked by uid 22791); 17 Jun 2011 19:03:05 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST X-Spam-Check-By: sourceware.org Received: from mail-pv0-f175.google.com (HELO mail-pv0-f175.google.com) (74.125.83.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 17 Jun 2011 19:02:51 +0000 Received: by pvc30 with SMTP id 30so781592pvc.20 for ; Fri, 17 Jun 2011 12:02:50 -0700 (PDT) MIME-Version: 1.0 Received: by 10.68.14.226 with SMTP id s2mr1179277pbc.252.1308337370502; Fri, 17 Jun 2011 12:02:50 -0700 (PDT) Received: by 10.68.47.71 with HTTP; Fri, 17 Jun 2011 12:02:50 -0700 (PDT) In-Reply-To: References: Date: Fri, 17 Jun 2011 19:24:00 -0000 Message-ID: Subject: Re: [Patch, libfortran] PR 49296 List read of file without EOR From: Janne Blomqvist To: Fortran List , GCC Patches Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 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 X-SW-Source: 2011-06/txt/msg01357.txt.bz2 PING. Also, here's a slightly simplfied testcase: ! { dg-do run } ! PR 49296 List formatted read of file without EOR marker (\n). program read_list_eof_1 implicit none character(len=3D100) :: s call genfil () open (unit=3D20, file=3D'read.dat', form=3D'FORMATTED', action=3D'READ', & status=3D'OLD') read (20, fmt=3D*) s close (20, status=3D'delete') if (trim(s) /=3D "a") then call abort () end if contains subroutine genfil open(10, file=3D'read.dat', form=3D'unformatted', action=3D'write', & status=3D'replace', access=3D'stream') write(10) 'a' close(10) end subroutine genfil end program read_list_eof_1 On Sat, Jun 11, 2011 at 13:05, Janne Blomqvist wrote: > Hi, > > attached patch fixes PR 49296. A new test for the testsuite is also inclu= ded. > > Regtested on x86_64-unknown-linux-gnu, Ok for trunk? > > 2011-06-11 =C2=A0Janne Blomqvist =C2=A0 > > =C2=A0 =C2=A0 =C2=A0 =C2=A0PR libfortran/49296 > =C2=A0 =C2=A0 =C2=A0 =C2=A0* io/list_read.c (read_character): Accept EOF = as a separator when > =C2=A0 =C2=A0 =C2=A0 =C2=A0reading string. > > > -- > Janne Blomqvist > --=20 Janne Blomqvist