Ok. I'am finally beginning to see where the word emulator comes in now. So apart from isatty(), are there a number of other calls to watch for, is there documentation online for this.
Strange, but I made a console application and redirected the stdout and stderr the way you instructed, but to a file and it worked just fine. How did the isatty() function not pickup on this?
Strange, but I made a console application and redirected the stdout and stderr the way you instructed, but to a file and it worked just fine. How did the isatty() function not pickup on this?
Most utilities don't care, and shouldn't care. Their output is expected to be piped and redirected in creative ways. Only things like interactive editors and login systems check isatty().
Thanks for the help so far. With the time I have got, I managed to put together the app this far. Currently my only problem is I cant seem to send any keyboard input to the child process program. Please take a look at my code and advice.
You having put it in quote tags instead of code tags means I can't even quote it to get the program with sane indentation and must do it all by hand.. I'll take a look ati t...
---------- Post updated at 04:53 PM ---------- Previous update was at 04:45 PM ----------
Your program actually worked without modification, first try:
...though you forget to null-terminate your read string, read doesn't do that for you!
And depending on your system the pipe may actually buffer and wait forever. You should close() the pipe after you're done writing to it, to force it to send the stuff along before you try and read() from the other pipe.
Sorry about the QUOTE tags, just now seen the CODE one.
I suspected something of the sort, but didn't know whether it was a \n escape that was needed or something else. I guess now my biggest challenge is how to continuously send and receive text from a more interactive program. I was testing it with passwd and was unable to control the input and output correctly. Please help me understand how I can achieve this successfully. I suspect some looping will be required, don't have a clue where to start with that with all the pipe logic.
The only time I received an isatty related error was with a few interactive types of programs like top. It said that the tty check failed, just as you said some of them would. passwd on the other hand launches well and requests for some input. getting it this input and retrieving the next output is proving to be the challenge. I hope you are not saying that this method completely cannot work with interactive programs. If it is possible, I would be grateful for some pointers on how to go about it.
Hi, I was just wondering how to distinguish between the two terms:
1. Terminal emulator (vt100, vt220 and so on)
2. shell command line
Then i decided to conclude myself that these 2 are very equivalent. am I right? this actually came to my mind when I was using my HP-UX terminal.
I am... (1 Reply)
Hello Expert! :b:
Question for you guys, Can anyone tell me how to use terminal emulator on Windows XP to view Solaris config? I have no idea on Solaris and the only thing I could do is to boot it up. Honestly, I have given a tasked to delete all the files and some necessary memory information... (2 Replies)
Hey,
Had anyone tried with writing a new FS - file system ( whether its useful or not, that doesn't matter ) ?
I tried one couple of years ago, but that was a fatal failure :( and can't continue working on it since then. :(
Anybody got some experience with writing file system from the... (4 Replies)
hi all,
i'm trying to write a unix system from scratch (not re-writing the kernel)
does anyone have information about that? tips and stuff...?i would appreciate every help,
thnks :) (9 Replies)
hello,
can any body tell how to use terminal emulator....
i want to check he serial port communication with the help of that terminal emmulator....
also tell me how to open terminal emmulator.....and how to configure it........and how to use it...
I am using fedora core 6..... (1 Reply)