--- deliantra/server/socket/lowlevel.C 2007/03/14 00:04:59 1.35 +++ deliantra/server/socket/lowlevel.C 2007/03/14 15:44:47 1.36 @@ -204,7 +204,7 @@ {"reply", SC(ReplyCmd) 0 }, {"exti", SC(ExtiCmd) 0 }, /* CF+ */ {"addme", SC(AddMeCmd) 0 }, - {"askface", SC(SendFaceCmd) 0 }, /* Added: phil */ + {"askface", SC(AskFaceCmd) 0 }, {"requestinfo", SC(RequestInfo) 0 }, {"setfacemode", SC(SetFaceMode) 0 }, {"setsound", SC(SetSound) 0 }, @@ -418,7 +418,9 @@ if (len + outputbuffer.len > SOCKETBUFSIZE) { LOG (llevDebug, "socket on fd %d has overrun internal buffer - marking as dead\n", fd); - destroy (); + // shutdown the socket, this is safer than destroying it immediately + // as lots of code in the callchain might still access the map etc. + shutdown (fd, SHUT_RDWR); return; }