• 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
Not using NSTask, but need the same functionality.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Not using NSTask, but need the same functionality.


  • Subject: Not using NSTask, but need the same functionality.
  • From: Chilton Webb <email@hidden>
  • Date: Thu, 14 Mar 2002 13:37:58 -0600

Greetings fellow hairdryer enthusiasts,

My Cocoa app calls a Unix program, eh, 'standard tool' or whatever we call them. That tool is a server written in raw c. And as luck would have it, I need to call another app, or rather, a few things, including a perl script and some other things that I can do relatively easily from a shell.

For that matter, I can do this with NSTask with no problem from within my app, but my client has requested that the server itself (aka the 'tool') stay as cross-platform as possible, and it really needs to be doing the calling.

So I've been looking into using popen, but when I do that some things like line lengths (wrapping) seem to be getting in my way. So is there a better way to do this without using NSTask? Also, is it possible to capture the stderr using a shell created with popen?

I'm asking here because some of the output is communicating with my actual app, which is Cocoa, and is using NSTask. I'm looking for maximum compatibility.

Thanks,
-Chilton
_______________________________________________
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: Image capture from USB digital cameras?
  • Next by Date: Re: MallocDebug: Can it be used at all?
  • Previous by thread: Re: Passing object graphs bycopy (was: DO, bycopy)
  • Next by thread: Searching something in a NSTextView
  • Index(es):
    • Date
    • Thread