On Tue, Jan 27, 2009 at 8:33 AM, JongAm Park
<joshua_park2006-applel...@yahoo.com> wrote:

> However, I have difficulty in making it to send data and receive ack from a
> server.
> Sometimes, it receives some meaningful data about changed information from a
> server, if a client send a request to change some data.
> But sometimes it also receives ack.
> So, I would like to make it do next job after receiving an ack.

OK sounds good so make it do the next job.

> So, I embraced a send routine with a lock. But the whole client process is
> in dead-lock status, because it is not multi-threaded.
> ( a receive routine already locked. )

A lock? As in NSLock, etc.? Why do you think you need a lock here
given it isn't multi-thread and the fact that IO appears to be driven
by a runloop which will serialize access for you.

> Under this situation, is there a good network programming model or pattern?
> How should I solve this issue?

You gave us very little actionable information, we can only guess at
your implementation. You will have to provide more details and ideally
sample code.

-Shawn
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to