Issue with telnet clients, crash on bigger data

Posted by Jedhi on Thu 14 Jul 2016 04:41 AM — 7 posts, 28,515 views.

#0
Hello!

I was entertaining the idea of writing my own MUD client for aardwolf, but ran into the problem. If i spam areas command few times, the client exits with a message, that server closed the connection.

First i figured it was my nodejs code, but then i tried same thing with telnet client that comes with Arch Linux.


➜  ~ telnet aardmud.org
Trying 66.228.127.34...
Connected to aardmud.org.
Escape character is '^]'.
#############################################################################
##[        --- Welcome to Aardwolf MUD ---        ]##########################
##[                                               ]############ /"  #########
##[         Players Currently Online: 199         ]########  _-`"""', #######
##[                                               ]#####  _-"       )  ######
##[     Game Last Rebooted on 16 Feb 19:51:19     ]### _-"          |  ######
################################################### _-"            ;  #######
######################################### __---___-"              |  ########

...

[62703/62703hp 23066/23101mn 3562/3562mv 0qt 307tnl] > areas
             [ Listing all areas in range 1 to 210 ]

From To   Lock  Builder          Area Name                      
---- ---- ----  ---------------  ------------------------------
   1    5       Domain           Kimr's Farm                   
   1    5       Klauwaard        Lowlands Paradise '96   

...

  80  100       Domain           The Realm of the Hawklords    
  80  100   50  Windjammer & Ja  Wedded Bliss                  
  80  110   50  Maerchyng        Anthrox                       
  80  110   50  Terrill & Citro  Island of Lost Time           
  80  110   50  Lumina Timeghos  Realm of the Firebird         
  80  130   60  Chade            Deathtrap Dungeon             
  90  110   70  Schizo & Cera    Pompeii                       
  90  110 onnection closed by foreign host.
➜  ~ 
➜  ~ telnet --version
telnet (GNU inetutils) 1.9.4
Copyright (C) 2015 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Written by many authors.



I have tried dedicated MUD clients like Mush, TinTin, Mudlet and none of them have this problem.

Any idea what do mud clients have that telnet clients do not?
Amended on Thu 14 Jul 2016 04:42 AM by Jedhi
#1
Got this "bug" fixed by enabling MCCP support!
USA Global Moderator #2
Sounds like you didn't actually fix the bug then, you just deferred it. The problem is that you've overrun your socket buffer by receiving more network data faster than you can handle it and clear it from the buffer. MUSHclient also has this problem because it doesn't grow its buffers. Do a note list on Aardwolf on board with many notes. Even with MCCP enabled you'll still get disconnected.
Amended on Wed 20 Jul 2016 07:48 PM by Fiendish
Australia Forum Administrator #3
The network data should not arrive faster than the client can handle it. You may as well say you are reading a big file, and the program crashes because the file is over a megabyte. However you read it in chunks that the program can handle.
USA Global Moderator #4
Note I think the word "crash" in the thread subject is wrong. It's a disconnect, not a crash. Every client I've tried, including MUSHclient, will disconnect from Aardwolf if you do a command that outputs a lot of information like `board ideas;note list`.
Amended on Sat 23 Jul 2016 10:18 AM by Fiendish
Australia Forum Administrator #5
Quote:

MUSHclient also has this problem because it doesn't grow its buffers.

...

Every client I've tried, including MUSHclient, will disconnect from Aardwolf if you do a command that outputs a lot of information ...


So, it might be a bug in Aardwolf, then?

Maybe Aardwolf needs to grow its buffers? Or it hits an internal limit and just disconnects?
USA Global Moderator #6
Yeah, you're probably right.