telnet window size question

Hello!

I'm writing a small telnet client using Erlang and the gen_tcp library.

I receive IAC WILL ECHO and IAC WILL SUPPRESS_GO_AHEAD
which I respond to.

Then I receive various text output from the server, and then this:

resize: unknown character, exiting.

I'm curious as to why I do not get an IAC request for NAWS according to RFC 1073 - Telnet window size option

I tried sending IAC WILL NAWS to no avail.

Any idea what I can send to the server in order to set the window size?

As I do now have any window, I would like as large window size as possible to ease with parsing the server output.

Cheers,
Gustav

Not all telnet servers abide by every conceivable option.