• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: After Autoreleasing Still Getting Leaked
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: After Autoreleasing Still Getting Leaked


  • Subject: Re: After Autoreleasing Still Getting Leaked
  • From: Scott Ribe <email@hidden>
  • Date: Wed, 15 Jun 2011 13:13:19 -0600

On Jun 15, 2011, at 1:04 PM, Bing Li wrote:

> I test the program just on a single Mac machine using TCP, i.e., both the client and the server are located on the same machine. So I think it is impossible that the data is corrupted during the transmission.

Correction to my prior post: even if all your strings are < 1024 bytes, you still have no guarantee that they won't be broken in the middle of a multi-byte sequence. On the sending end, multiple short strings might get packed into a single packet > 1024 bytes. Your receiving end is not going to be reliable unless you only use 7-bit ASCII--and even then you need the appropriate logic in receivedMessage to recognize message boundaries, append bytes to a buffer until you have a full message, and so on.

--
Scott Ribe
email@hidden
http://www.elevated-dev.com/
(303) 722-0567 voice




_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: After Autoreleasing Still Getting Leaked
      • From: Bing Li <email@hidden>
References: 
 >After Autoreleasing Still Getting Leaked (From: Bing Li <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Scott Ribe <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Bing Li <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Scott Ribe <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Jens Alfke <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Scott Ribe <email@hidden>)
 >Re: After Autoreleasing Still Getting Leaked (From: Bing Li <email@hidden>)

  • Prev by Date: Re: Interface item validation through first responder
  • Next by Date: [iOS] What's the point of UISegementedControl.tintColor?
  • Previous by thread: Re: After Autoreleasing Still Getting Leaked
  • Next by thread: Re: After Autoreleasing Still Getting Leaked
  • Index(es):
    • Date
    • Thread