• 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
Is CpMac sick?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Is CpMac sick?


  • Subject: Is CpMac sick?
  • From: Steve Gehrman <email@hidden>
  • Date: Thu, 28 Jun 2001 20:44:25 -0700

I've been trying to get CpMac to work. It works for some small files and folders, but on one of my folders CpMac returns with this....

"could not open the destination file (-5000)"

In another case I call CpMac repeatedly as I enumerate over a folder, for some reason after 6mbs of successful copying my code trys to allocate a pipe and it returns nil ie....

errorPipe randomly returns nil and the debugger complains when I set nil to StandardError. anyone else seen this kind of behavior. I'm using the same NSTask code for many other tasks which have never given me problems.

BOOL result;
NSTask *task = [[ NSTask alloc ] init ];
NSPipe *outputPipe = [[NSPipe alloc] init];
NSPipe *errorPipe = [[NSPipe alloc] init];
NSFileHandle *readHandle;
NSData *availableData;
NSString* outString;

[ task setCurrentDirectoryPath: currentDirectory ];
[ task setLaunchPath:toolPath];
[ task setArguments: args ];
[ task setStandardOutput: outputPipe ];
[task setStandardError:errorPipe];

steve


  • Prev by Date: Re: Help! My airplane is missing!
  • Next by Date: Re: AppKit source available as reference?
  • Previous by thread: Re: Files attributes
  • Next by thread: packaging external binaries
  • Index(es):
    • Date
    • Thread