Date: Fri, 09 Nov 2001 08:24:53 +0200 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: Robert Neinast Message-Id: <8011-Fri09Nov2001082452+0200-eliz@is.elta.co.il> X-Mailer: emacs 21.1.50 (via feedmail 8 I) and Blat ver 1.8.9 CC: djgpp AT delorie DOT com In-reply-to: (message from Robert Neinast on Thu, 08 Nov 2001 20:19:04 GMT) Subject: Re: Can't Even Read File Correctly References: <9sei6v$8j9$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > From: Robert Neinast > Newsgroups: comp.os.msdos.djgpp > Date: Thu, 08 Nov 2001 20:19:04 GMT > > One more question: Is there any way to start up bash so that > the default is "binary", not "text" mode No. Bash has nothing to do with this: each program needs to to set the text/binary mode by itself, because the CRLF -> LF conversions are done by the library, not by the OS. So the text/binary mode cannot be inherited to child processes, and therefore Bash cannot force the programs it runs into some specific mode. > It really annoys me that programs like > ls, wc, and od count those \r\n when its only \n that's there > (i.e., they give false counts). Hm?? Those \r\n pairs _are_ there in the file, wc doesn't invent them. Try running a file through dtou, and you will see that wc reports rediced counts, and the file's size on disk also gets smaller. wc reads its files in binary mode.