.
D 2000-10-26T00:56:10
J assignee nobody
J cmimetype text/plain
J comment OriginalBugID:\s3841\sBug\nVersion:\s8.2.2\nSubmitDate:\s'1999-12-10'\nLastModified:\s'2000-04-19'\nSeverity:\sSER\nStatus:\sClosed\nSubmitter:\stechsupp\nChangedBy:\shobbs\nOS:\sSolaris\nOSVersion:\sSolaris\s2.7\nMachine:\sUE2\sUE450\nFixedDate:\s'2000-10-25'\nClosedDate:\s'2000-04-19'\n\n\nName:\nChristian\sWilliams\n\nComments:\nwe\suse\sa\sTcl-based\schat\sserver\son\sour\sweb\ssite;\severy\stime\sa\sclient\sbecomes\nunreachable\s(i.e.,\sits\scomputer\scrashes,\sgoes\soffline,\setc),\sthe\swhole\sserver\nfreezes\sup\sfor\sas\smuch\sas\s60\sseconds,\swhile\sUnix\sdecides\sthat\sthe\sconnection\nis\sdead\sand\sreturns\san\serror\son\sthe\ssend().\s\sobviously\sthis\sisn't\sa\sgreat\suser\nexperience,\sand\sis\sour\s#1\scomplaint\sfrom\sour\susers.\n\napart\sfrom\sthis\sproblem,\sTcl\sworks\sgreat\sas\sa\sserver\sof\sthis\ssort.\n\nReproducibleScript:\nrun\sthis\sscript\sfrom\sone\shost:\n--------------------------------------------\nproc\srun\s{\ssock\sargs\s}\s{\n\s\sputs\s"Got\sconnection...\shit\sreturn\sto\swrite"\n\s\sgets\sstdin\n\s\sset\sx\s0\n\s\swhile\s{$x\s<\s10000}\s{\n\s\s\s\sputs\s-nonewline\s"\\r$x\sbytes";\sflush\sstdout\n\s\s\s\sputs\s-nonewline\s$sock\s".";\sflush\s$sock\n\s\s\s\sincr\sx\n\s\s}\n\s\sputs\s"";\sexit\n}\n\nsocket\s-server\srun\s6666\nvwait\sforever\n--------------------------------------------\n\non\sanother\shost,\sconnect\sto\sthat\sport:\n\s\s\stelnet\shosta\s6666\n\nnow\sunplug\sthe\snetwork\sconnection\sof\sthe\ssecond\shost,\sand\shit\nreturn\son\sthe\sfirst.\s\sthe\sscript\swill\soutput\sdata\suntil\sit\sfills\sUnix's\nsend\sbuffer,\sthen\sblock\sin\sthe\sputs.\s\sthis\sbehaviour\sis\sthe\ssame\nno\smatter\swhat\sthe\ssocket's\sfconfigure\soptions\sare.\n\nObservedBehavior:\n.....\nsend(4,\s"\s.",\s1,\s0)\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s=\s1\nwrite(1,\s"\\r\s8\s1\s9\s2\s\s\sb\sy\st\se\ss",\s11)\s\s\s\s\s\s\s\s\s\s=\s11\nsend(4,\s"\s.",\s1,\s0)\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s\s=\s1\nwrite(1,\s"\\r\s8\s1\s9\s3\s\s\sb\sy\st\se\ss",\s11)\s\s\s\s\s\s\s\s\s\s=\s11\nsend(4,\s"\s.",\s1,\s0)\s\s\s\s\s\s\s\s\s\s\s\s\s(sleeping...)\n\nDesiredBehavior:\nthe\sfblocked\scommand\sshould\sindicate\swhether\sa\sputs\swill\sactually\sblock,\nor\sthere\sshould\sbe\sa\sconfigurable\sbuffer\ssize\sfor\swrites,\nor\sTcl\sshould\sreturn\san\serror,\nor\sANYTHING\sbut\sblocking!\s\s\s\s\s;\s)\n\n\n\nThe\suser\smentions\sfblocked,\sbut\sI\sdon't\ssee\sit\sused.\s\sIn\sfact,\nit\slooks\slike\sthis\smight\sall\sbe\scleared\sup\sif\sthe\suser\swere\nto\suse\snon-blocking\ssockets\sthroughout\sand\sbase\sit\sall\son\nfileevents.\s\sUnless\sthat\scase\salso\shangs\s(which\sisn't\sspecified).\s\n--\s04/19/2000\shobbs
J foundin obsolete:\s8.2.2
J priority 5\sMedium
J resolution None
J status Open
J submitter nobody
J subsystem 63.\s(unused)
J title socket\swrites\shanging\sif\sendpoint\scan't\sbe\sreached
J type Bug
K 218324ffffffffffffffffffffffffffffffffff
U nobody
Z c008b5e4b8f24e51a3bf9529b51539bd