Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CFSocketSendData silently dropping packets




On May 29, 2006, at 22:03 , Andrew White wrote:


When ARP resolution is slow, my CFSocketSendData call silently fails to
send packets.
[snip]
I fire off three of these messages in quick succession. If the arp cache
is not primed the Mac must perform arp resolution. Sometimes, the arp
message takes as long as 1-2 ms to return. In such cases, the first two
messages return success (or don't trigger the log messages, in any case)
but fail to actually be written to the network. The third message is
correctly sent.

This is the way ARP support is implemented: the last-sent packet to a specific address is kept; previous ones are dropped.


I would have assumed that either the messages would be sent or that they
would get a timeout fail, not that they would be reported as successful and
not sent. Can anyone shed some light on my situation?

Yup. UDP datagram service does not guarantee delivery. The udp code takes the packet from the sender, readies it for output, and sends it on its way. No buffering takes place. If you send too quickly, you get the behavior you are seeing. This is part of the protocol definition, rather than an implementation issue.


Cheers,

Justin


-- Justin C. Walker, Curmudgeon at Large Institute for the Absorption of Federal Funds ----------- My wife 'n kids 'n dogs are gone, I can't get Jesus on the phone, But Ol' Milwaukee's Best is my best friend. -----------


_______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/email@hidden

This email sent to email@hidden
References: 
 >CFSocketSendData silently dropping packets (From: Andrew White <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.