diff --git a/flang/runtime/descriptor-io.h b/flang/runtime/descriptor-io.h --- a/flang/runtime/descriptor-io.h +++ b/flang/runtime/descriptor-io.h @@ -176,7 +176,7 @@ if (!EditCharacterOutput(io, *edit, x, length)) { return false; } - } else { + } else { // input if (edit->descriptor != DataEdit::ListDirectedNullValue) { if (EditCharacterInput(io, *edit, x, length)) { anyInput = true; diff --git a/flang/runtime/edit-input.cpp b/flang/runtime/edit-input.cpp --- a/flang/runtime/edit-input.cpp +++ b/flang/runtime/edit-input.cpp @@ -693,9 +693,6 @@ return false; } const ConnectionState &connection{io.GetConnectionState()}; - if (connection.IsAtEOF()) { - return false; - } std::size_t remaining{length}; if (edit.width && *edit.width > 0) { remaining = *edit.width;