The way errors are sent from the tty handler does not really work.
The wire format was supposed to be [sizeof(msg)][msg], however this was never implemented correctly and even had some compiler warnings (depending on what version/compiler was used).
Right now it is just writing the raw message to the socket... this can work if we close the connection down and then can just read to EOF... but I don't really like this.
The way errors are sent from the tty handler does not really work. The wire format was supposed to be
[sizeof(msg)][msg]
, however this was never implemented correctly and even had some compiler warnings (depending on what version/compiler was used).Right now it is just writing the raw message to the socket... this can work if we close the connection down and then can just read to EOF... but I don't really like this.