Re: ctl_enqueuedata() woes - FIXED
site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Yes, if this is a SOCK_DGRAM socket, specifying 0 will cause the current data to be appended to the previous one in the socket without a message boundary. A read done on the socket will either truncate or discard data enqueued to it after the 1st one. That's what CTL_DATA_EOR is for, as you've already discovered. Adi On Oct 4, 2007, at 8:16 AM, Karl Pickett wrote: On 10/3/07, Adi Masputra < adi@apple.com> wrote: How are you calling ctl_enqueuedata() -- i.e. what are its parameters? Adi I tested it, that was indeed the problem. Thanks! _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com I was calling it with 0 for flags, as per the example code. Gee. I was wondering what CTL_DATA_EOR was for since the example didn't use it. It looks like my code and the example code would be better off using CTL_DATA_EOR :) -- Karl Pickett "They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety." -- Benjamin Franklin "Eternal vigilance is the price of liberty." -- Wendell Phillips "One man with courage makes a majority." -- Andrew Jackson, 1832 smime.p7s
participants (1)
-
Adi Masputra