lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Fri, Dec 3, 2010 at 19:40, Stuart P. Bentley <stuart@testtrack4.com> wrote:
> ?What spec allows just CR? Every spec I've ever heard of mandates CRLF for
> transport.
>
> -----Original Message----- From: HyperHacker
> Sent: Tuesday, November 30, 2010 P8:46 Newsgroups:
> gmane.comp.lang.lua.general
> To: Lua mailing list
> Subject: LuaSocket Patch for CR Handling
>
> I've been playing with IRC for a bit now and one thing that's been
> bothering me is that the specs allow for a line to be terminated with
> just CR. LuaSocket however discards CRs and treats only LF as line
> break, which means any IRC client using it can't easily conform to the
> spec.
>
> I decided to fix this with a simple patch to recvline(); it now
> accepts CR, LF, or CR LF as line breaks. I didn't test this
> extensively, but everything still seems to be working, so here we go.
>
> --
> Sent from my toaster.
>
>

Hm, well looking at it again I think I may have misunderstood the
spec... oh well. Maybe someone will find a use for it...

-- 
Sent from my toaster.