Re: NSTask & curl
Re: NSTask & curl
- Subject: Re: NSTask & curl
- From: Nick Zitzmann <email@hidden>
- Date: Sat, 6 Jun 2009 15:29:48 -0600
On Jun 6, 2009, at 3:18 PM, Ammar Ibrahim wrote:
The problem is that in my delegate I can't access the file! Although
I can
see it on the filesystem and open it. even if I check if the file
exists
from the delegate, it gives me "false". Why is this happening? How
can I fix
it
Well, let's see...
task = [[NSTask init] alloc];
For starters, you wrote this backwards.
I also don't see any place where you're registering for any
notifications, nor are you releasing the task object (which is fine if
you're using GC).
But the best thing you can do is not use NSTask if you can do the job
without NSTask. In this case, you ought to consider using
NSURLDownload instead of NSTask, unless the URL is a TFTP URL or some
other URL scheme that is not handled by NSURLConnection/NSURLDownload.
Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
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