home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.protocols.tcp-ip      TCP and IP network protocols.      14,669 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 13,935 of 14,669   
   Les Cargill to Jorgen Grahn   
   Re: send() crash   
   14 Feb 13 18:22:11   
   
   From: lcargill99@comcast.com   
      
   Jorgen Grahn wrote:   
   > On Thu, 2013-02-14, Les Cargill wrote:   
   >> Rick Jones wrote:   
   > ...   
   >>> What do you mean by send() "crashes?"   
   >>   
   >> The program exits without complaint.   
   >   
   > That's another way of saying "send() does not crash but returns, and   
   > my own program logic, which I haven't shown you, does something which   
   > end with an exit(0) or a return 0 from main()".   
   >   
      
   (dots are not varargs stuff in this, but rather ellipses for English   
   purposes).   
      
   I have a construct (macro) called "trace()" that puts stuff out the   
   console using printf(...,__LINE__) ,  fflush() and usleep() in   
   that order. I've yet to catch it not generating output. Of course it's   
   invasive, but it's for finding crashes...   
      
   I bracketed the send() call with those. The first one is seen; the   
   second one is not.   
      
   trace();   
   ... = send(...);   
   trace();   
      
   Never say never, but I am pretty confident that the send was   
   the last thing that happened. The console is a serial port at 115kbit,   
   and I set the usleep() to be twice the number of character times   
   of the previous printf();   
      
   > The socket questions (which I didn't read) are still relevant I guess,   
   > but only you can tell what really happens in your program, and what   
   > really does happen when you call send().  The easiest way may be to   
   > get strace(1) to run on your system,   
      
   Agreed; it might be time to try to get strace() to work on this   
   system. It's BusyBox/ash so I've been avoiding that...   
      
   > and use it to get a trace of the   
   > system calls.   
   >   
   > /jORGEN   
   >   
      
   --   
   Les Cargill   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca