• 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
Re: Debugging Stdout
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Debugging Stdout


  • Subject: Re: Debugging Stdout
  • From: Ronnie O <email@hidden>
  • Date: Tue, 4 Oct 2005 19:27:18 -0400

Thanks for all the suggestions, before I comment on any of them, I
found something pretty significant.

If I make the call to the c command line utility from my cocoa app, a
debug file is created.  If I check the debug file before I close the
cocoa app, it is only half-way created.  It stops right before where
it should print the stdin data.  So I make calls to the c program and
nothing appears in my textView.  Once I close the cocoa app and check
the debug file, it then has been fully created.  It contains a print
of the stdin text data and appears correct and complete.  I don't
think I had ever previously checked the debug file in mid-processing
and didnt realize my task wasnt running to completion until I closed
the cocoa app.  This is why I wasnt receiving any data returned from
stdout to my textView.  Does this behavior raise any flags??  As I
stated previously, the perl script is having no issues with my
existing code.  Why isnt my c task running to completion until I
terminate my cocoa app??

In response to the previous possible solutions:

1) I had already included this:

[environment setObject:@"YES" forKey:@"NSUnbufferedIO"];
[task setEnvironment:environment];

So should this take care of any buffering issues by the c program?

2)I do have a standard error pipe set up which has successfully piped
error messages previously.  It is regsitered for notifications, so I
would be aware of the stdout data arriving there.

I will comment on the rest as necessary.  Thanks again to all for your ideas!
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Debugging Stdout
      • From: Sherm Pendley <email@hidden>
References: 
 >Debugging Stdout (From: Ronnie O <email@hidden>)
 >Re: Debugging Stdout (From: Frode <email@hidden>)
 >Re: Debugging Stdout (From: Alastair Houghton <email@hidden>)

  • Prev by Date: newbie interface problem
  • Next by Date: Core Data - awakeFromInsert
  • Previous by thread: Re: Debugging Stdout
  • Next by thread: Re: Debugging Stdout
  • Index(es):
    • Date
    • Thread