• 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
NSTask: Too many arguments *only* in debugger
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTask: Too many arguments *only* in debugger


  • Subject: NSTask: Too many arguments *only* in debugger
  • From: Charles Srstka <email@hidden>
  • Date: Thu, 30 Jan 2003 21:44:27 -0600

Okay, here's a weird one for you. I have a Cocoa app that uses a command-line tool to do something. It passes that tool a really long list of files. The number of characters in the command line is *almost, but not quite* the maximum number of characters allowed in a command line. The thing is, it works great when I run the executable normally. When I run it in the debugger, I get this:

*** NSTask: Task create for path <some tool> failed: 7, "Argument list too long".

The thing is, I've logged the total length of the launch path + the lengths of all the arguments + a space between each, and:

1. It logs the exact same number both times,
2. The number is always less than the arg max, and
3. It throws an exception in the debugger, works fine otherwise.

Does NSTask add some arguments when it's being run in debug mode or something?

Charles
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: FindFolder() and Cocoa
  • Next by Date: cronjob, crontab wrapper classes
  • Previous by thread: IB bug
  • Next by thread: cronjob, crontab wrapper classes
  • Index(es):
    • Date
    • Thread