Re: Mac text files and gets()

new topic     » topic index » view thread      » older message » newer message

CChris wrote:
> 
> Pete Lomax wrote:
> > 
> > this whole thread is probably moot anyway...
> > 
> 
> Actually, the mod as I implemented it works fine under DOS/Windows, because
> the OS takes care of removing the \r.
I see, so the mod you suggested does nothing to fix the problem you reported.

> If we are to avoid this, then it looks like, under Linux/BSD, we'd need a one
> char lookahead buffer for gets(). Its contents would be needed so as to
> recoginse
> \r\n as \n, eliminating both the trailing \r and the spurious empty ine. 

You obviously did not read the rest of my post:
http://www.openeuphoria.org/EUforum/m16613.html

Pete

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu