#7468: incorect waiting for packets on UDP connections.
------------------------------------------+---------------------------------
  Reporter:  ET                           |          Owner:                  
      Type:  bug                          |         Status:  closed          
  Priority:  normal                       |      Milestone:                  
 Component:  libraries/base               |        Version:  7.4.1           
Resolution:  invalid                      |       Keywords:  UDP packet loss.
        Os:  Linux                        |   Architecture:  Unknown/Multiple
   Failure:  Incorrect result at runtime  |     Difficulty:  Unknown         
  Testcase:                               |      Blockedby:                  
  Blocking:                               |        Related:                  
------------------------------------------+---------------------------------
Changes (by simonmar):

  * status:  new => closed
  * difficulty:  => Unknown
  * resolution:  => invalid


Comment:

 This is not a bug - Handles have buffers, so when you use `hWaitForInput`,
 the input is read into the buffer.  The `recv` function doesn't read from
 the `Handle`, so it doesn't see the data in the buffer.  The rule of thumb
 is that if you turn a socket into a `Handle`, you should use the `Handle`
 operations for reading and writing from then on.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7468#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to