diff --git a/dlls/msvcrt/file.c b/dlls/msvcrt/file.c index 9fe09ddd000..ba5b445ce49 100644 --- a/dlls/msvcrt/file.c +++ b/dlls/msvcrt/file.c @@ -1634,6 +1634,19 @@ static int read_i(int fd, void *buf, unsigned int count) */ if (ReadFile(hand, bufstart, count, &num_read, NULL)) { + if (MSVCRT_fdesc[fd].wxflag & WX_TEXT) + { + int i; + /* in text mode, a ctrl-z signals EOF */ + for (i=0; i