Skip to content

Commit 8afd02e

Browse files
committed
Just set isize=0 (for NAG)
1 parent ebea5e1 commit 8afd02e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/json_module.f90

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4285,14 +4285,11 @@ subroutine get_current_line_from_file(iunit,line)
42854285
![the line is read in chunks until the end of the line is reached]
42864286
if (istat==0) then
42874287
do
4288+
isize=0
42884289
read(iunit,fmt=nfmt,advance='NO',size=isize,iostat=istat) chunk
42894290
if (istat==0) then
42904291
line = line//chunk
42914292
else
4292-
!avoid a comparison to isize if EOF is at the start of object
4293-
![some compilers will leave isize uninitialized for this case]
4294-
if (index(err_message, &
4295-
"Unexpected end of file while parsing start of object") > 0) exit
42964293
if (isize>0 .and. isize<=n_chunk) line = line//chunk(1:isize)
42974294
exit
42984295
end if

0 commit comments

Comments
 (0)