Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!uunet!ibism!ibism.UUCP!lcp From: lcp@ibism.UUCP (Larry Poleshuck) Newsgroups: comp.windows.x Subject: Re: "wake up" XtAppMainLoop Message-ID: <12053@ibism.uucp> Date: 23 Oct 90 17:07:55 GMT References: <9954@uhccux.uhcc.Hawaii.Edu> Sender: news@ibism.uucp Reply-To: ibism!lcp Organization: Citibank IBISM Lines: 35 In article <9954@uhccux.uhcc.Hawaii.Edu>, lim@wiliki.eng.hawaii.edu (Lim Kok Kian) writes: > I'm sure this has been asked before and I am sure there got to > be a way to get around with the following problem I have : > > In my application I fork a child and do something and the child > process will generate data and after so many data generated > I want the parent process which is the application to be able to read > or get the data and display that on the appication screen. > > My question is : Is there a way to wake up the XtAppMainLoop from > the child .... say may be using some kind of signal ? > > Any Help would be appreciated ... > but please email me directly cause I didn't keep up with this newsgroup! > Thanks > > aloha > --lim Create a pipe for communicating with your child. Your child writes to the pipe and your parent calls XtAddInput with the XtInputReadMask. When data appears on the pipe the function specified by XtAddInput will be executed. You then read() on the pipe. Be careful to check that data has come across the pipe. -- Larry Poleshuck Citibank 111 Wall Street New York, NY 10043 Phone: 212-657-7709 Fax: 212-657-0068 E-Mail: uunet!ibism!lcp