OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [namelist_empty.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! { dg-options "-std=legacy" }
3
!
4
! pr24584, segfault on namelist reading an empty string
5
! Contributed by Jerry DeLisle  
6
      implicit none
7
      character*20   temp
8
      character(len=10) var
9
      namelist /input/ var
10
      var = 'Howdy'
11
      open(unit=7, status="scratch")
12
      temp = '   var='''''  ! var='' in the file
13
      write(7,'(A6)') '&INPUT'
14
      write(7,'(A10)') temp
15
      write(7,'(A1)') '/'
16
      rewind(7)
17
      read(7,NML=input)
18
      close(7)
19
      if (var.ne.'') call abort
20
      end

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.