Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

clear or flush pending I/O

clear or flush pending I/O

clear or flush pending I/O

Trapping the interrupt (^C) fails if the signal is received during an I/O, i.e. I can jump to the desired location of a program but then I cannot perform any other I/O but that passing through an emergency call system ....
What I need is a system call clearing the pending I/O - excuse me, but I do not know how to format the page
WRITE (6,*) 'press control-C'
READ (5,*) I
CALL SYSTEM ('echo this is printed')
C I need a system call here
WRITE (6,*) 'but this not'

RE: clear or flush pending I/O

Which compiler/OS are you using?

RE: clear or flush pending I/O

g77 compiler with LINUX UBUNTU - sorry to have forgotten this info. I am new. pietrocomin

RE: clear or flush pending I/O

Seems to work for me. Prints both the system echo and the write 6. I am using gfortran 7.5.0 on ubuntu 18.04

RE: clear or flush pending I/O

you are right. I also find that with gfortran works. unfortunately gfortran does not allow to open more units to the same file and therefore I have not considered to check that g77 and gfortran work the same. thanks for your attention. good easter in delay.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close