crash with cfftpstream
crash with cfftpstream
- Subject: crash with cfftpstream
- From: Frederick Cheung <email@hidden>
- Date: Fri, 24 Sep 2004 02:20:36 +0200
I'm using CFFTPStream to list the files on an ftp server and I'm
getting a crash when I set kCFStreamPropertyFTPProxy.
I'm actually listing files recursively and have asked for persistent
connections (which I am getting). It never seems to crash on the first
listing, it's always some point further down the road
I am setting proxy settings like like so:
proxyDict=SCDynamicStoreCopyProxies(NULL);
if(proxyDict){
CFReadStreamSetProperty(readStreamRef,kCFStreamPropertyFTPProxy,proxyDic
t);
CFRelease(proxyDict);
}
My app crashes systematically if I do this, and never crashes if I do
not set the proxies. I don't use a proxy server, so the only key in the
dictionary that might be of use to CFFTPStream is the one relating to
passive FTP.
When the crash occurs, the backtrace looks like this:
Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_INVALID_ADDRESS (0x0001) at 0x776f726b
[snip]
Thread 7 Crashed:
0 libobjc.A.dylib 0x908311f4 objc_msgSend + 0x14
1 com.apple.CFNetwork 0x92757be8
_CFNetworkFindProxyForURL + 0x104
2 com.apple.CFNetwork 0x9275b55c _FTPStreamOpen + 0x104
3 com.apple.CoreFoundation 0x901c2480 _CFStreamOpen + 0x74
4 com.apple.CoreFoundation 0x901cfaa4 CFReadStreamOpen + 0xac
I'm running my tests against an ftp server on my own machine so the url
looks like ftp://127.0.0.1/foo. It doesn't systematically crash on the
same URL every time.
Any ideas as to what is going on?
Fred
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden