Re: Displaying top
Re: Displaying top
- Subject: Re: Displaying top
- From: Peter Horn <email@hidden>
- Date: Tue, 14 May 2002 08:49:12 +0200
Hi!
Since I can only have one NSTask running,
I'll let top run until the button is clicked, stop the top NSTask,
create
the new NSTask for kill, and then start top again.
What about 'man 2 kill'?
The problem is that I can't get top to display. I've stripped out
everything
except the top-relevant code and it doesn't work. When I run the
following
code, all I get to display in textview is the string "can't get
terminal
attributes."
Top doesn't just show its result, but uses esc-characters to format
it. You can have a look at this:
> top > test.tst
...wait some time, then press 'q'...
> less test.tst
And theses characters depend on the settings for the current terminal.
Did you try 'top -l1'? I think that top will then create an
'unlimited' list of all running processes as plain text output --
and I guess that's very much what you want, anyway.
Peter
_______________________________________________
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.