gdk_add_input() Question
- From: Cory Prowse <cosmic uq net au>
- To: gtk-list redhat com
- Subject: gdk_add_input() Question
- Date: Sat, 9 Jan 1999 17:57:11 +1000 (GMT+1000)
G'Day,
I've come across a small hurdle with the use of gdk_add_input().
To simplify the whole problem I wrote an application which shows the
behaviour and it is available at:
http://www.uq.net.au/~zzcprows/development/
This program simply forks another process and runs a command (always
"./child-process", just symbolic link to the command you want) in the
subprocess, displaying the stdout and stderr of the process, and also
allows the user to send text to the child process's stdin.
The problem lies in using gdk_add_input() to monitor a pipe for data.
When a shell script is run the program works perfectly (one is included
"test.sh"). However when any binary is run as the child-process then
gdk_add_input() incorrectly reports that there is data to be read. The
callback function then blocks on the read operation in the callback
function, and the show stops there (bot only for a binary, shell scripst
work fine).
Am I incorrectly using the function?
Any help would be greatly appreciated and I thank you in advance for it.
PS: Remember that the program is simple, and it is hard coded to run the
child-process as "./child-process" so you will need to symbolic link to
"test.sh" to show it working.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Cosmic - cosmic@uq.net.au
http://www.uq.net.au/~zzcprows/
(PGP public key and ICQ number available)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]