On Thu, Sep 13, 2012 at 2:55 PM, Ralf Friedl <[email protected]> wrote:
> Denys Vlasenko wrote:
>>
>> Changed it to this in git:
>>
>>                 else if (c == '\r')
>> -                       outbuf[j++] = '\0'; /* CR -> CR NUL */
>> +                       /* See RFC 1123 3.3.1 Telnet End-of-Line
>> Convention.
>> +                        * Using CR LF instead of other allowed
>> possibilities
>> +                        * like CR NUL - easier to talk to HTTP/SMTP
>> servers.
>> +                        */
>> +                       outbuf[j++] = '\n'; /* CR -> CR LF */
>
> This sends a CR-LF End-of-Line, but as a response to Ctrl-M.

Is that wrong or what? I don't understand what you want to say.

> In line mode
> the telnet client reads Ctrl-J or LF when the user presses enter.

I am not even familiar with this line mode thingy.
Let me experiment... ok, so in line more we see '\n'
from keyboard, not '\r'.

> The right thing to do would be to revert this change and to add
> +  else if (c == '\n' && G.charmode != CHM_ON) {
> +    outbuf[j] = '\r'; /* LF -> CR LF */
>
> +    outbuf[j++] = '\n';
> +  }

Probably...
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to