public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "fxcoudert at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libfortran/25139] "Invalid argument" error on I/O
Date: Tue, 29 Nov 2005 12:29:00 -0000	[thread overview]
Message-ID: <20051129122954.5464.qmail@sourceware.org> (raw)
In-Reply-To: <bug-25139-10129@http.gcc.gnu.org/bugzilla/>



------- Comment #3 from fxcoudert at gcc dot gnu dot org  2005-11-29 12:29 -------
The testcase can be reduced further:

      integer dat(5)
      dat = (/ 0, 0, 0, 0, 1 /)
      write(11) dat,dat,dat,dat
      rewind 11
      write(11) dat
      read(11,end=1008) dat
 1008 continue
      backspace 11
      write(11) dat
      read(11,end=1011) dat
 1011 continue
      backspace 11
      backspace 11
      end

At line 13 of file testio2.f
Fortran runtime error: Invalid argument


>From looking at the fort.11 file, I think the output is correct at every point
of the program. Also note that if we comment two lines of this testcase, like
that:

      integer dat(5)
      dat = (/ 0, 0, 0, 0, 1 /)
      write(11) dat,dat,dat,dat
      rewind 11
      write(11) dat
      read(11,end=1008) dat
 1008 continue
!      backspace 11
!      write(11) dat
      read(11,end=1011) dat
 1011 continue
      backspace 11
      backspace 11
      end

then we get another error message (which shouldn't happen):

At line 10 of file testio2.f
Fortran runtime error: Read past ENDFILE record

I don't know yet if these bugs have the same cause.


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|2005-11-29 12:12:42         |2005-11-29 12:29:53
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25139


  parent reply	other threads:[~2005-11-29 12:29 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-28 16:52 [Bug libfortran/25139] New: Fortran runtime error: Invalid argument dir at lanl dot gov
2005-11-29  2:16 ` [Bug libfortran/25139] " jvdelisle at gcc dot gnu dot org
2005-11-29 12:12 ` [Bug libfortran/25139] "Invalid argument" error on I/O fxcoudert at gcc dot gnu dot org
2005-11-29 12:29 ` fxcoudert at gcc dot gnu dot org [this message]
2005-11-29 18:37 ` jb at gcc dot gnu dot org
2005-12-10 15:39 ` [Bug libfortran/25139] [4.1/4.2 regression] " fxcoudert at gcc dot gnu dot org
2005-12-10 16:39 ` fxcoudert at gcc dot gnu dot org
2005-12-12 16:38 ` dir at lanl dot gov
2005-12-12 16:50 ` dir at lanl dot gov
2005-12-13 14:39 ` dir at lanl dot gov
2005-12-13 15:21 ` dir at lanl dot gov
2005-12-16 20:35 ` dir at lanl dot gov
2005-12-19  8:12 ` fxcoudert at gcc dot gnu dot org
2005-12-19 18:40 ` mmitchel at gcc dot gnu dot org
2005-12-21 19:36 ` dir at lanl dot gov
2005-12-21 20:21 ` kargl at gcc dot gnu dot org
2005-12-21 21:43 ` dir at lanl dot gov
2005-12-21 22:14 ` fxcoudert at gcc dot gnu dot org
2005-12-22  1:19 ` jvdelisle at gcc dot gnu dot org
2005-12-22  2:08 ` jvdelisle at gcc dot gnu dot org
2005-12-22 14:00 ` dir at lanl dot gov
2005-12-22 14:18 ` dir at lanl dot gov
2005-12-22 14:24 ` fxcoudert at gcc dot gnu dot org
2005-12-22 16:01 ` dir at lanl dot gov
2005-12-22 16:32 ` dir at lanl dot gov
2005-12-22 17:59 ` jvdelisle at gcc dot gnu dot org
2005-12-22 19:23 ` dir at lanl dot gov
2005-12-22 21:14 ` dir at lanl dot gov
2005-12-22 22:49 ` jvdelisle at gcc dot gnu dot org
2005-12-22 23:03 ` jvdelisle at gcc dot gnu dot org
2005-12-23  0:21 ` jvdelisle at gcc dot gnu dot org
2005-12-23 15:14 ` dir at lanl dot gov
2005-12-23 20:21 ` jvdelisle at gcc dot gnu dot org
2005-12-28 20:58 ` jvdelisle at gcc dot gnu dot org
2005-12-28 21:12 ` jvdelisle at gcc dot gnu dot org
2006-01-01  3:49 ` jvdelisle at gcc dot gnu dot org
2006-01-01  3:53 ` jvdelisle at gcc dot gnu dot org
2006-01-01  5:14 ` jvdelisle at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051129122954.5464.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).