Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!cs.utexas.edu!ut-emx!ibmchs!auschs!awdprime!innerdoor.austin.ibm.com!jon From: jon@innerdoor.austin.ibm.com (Jon H. Werner) Newsgroups: comp.windows.x Subject: Re: VMS XtAddInput Keywords: addinput mailboxes Message-ID: <8138@awdprime.UUCP> Date: 3 Jun 91 16:45:52 GMT References: <166@thor.sdrc.com> Sender: news@awdprime.UUCP Distribution: usa Lines: 34 In article <166@thor.sdrc.com>, mustard@thor.sdrc.com (Sandy Mustard) writes: |> |> Hi, |> |> I'm having a problem with X on VMS that I'm hoping someone out there |> might be able to help me with. |> |> Basically I have a process that is running as an X client. It spawns |> using SYS$CREPRC a subprocess (right now I'm using LOGINOUT.EXE) and |> assigns newly created mailboxes to it's stdin, stdout and stderr. I |> issue a QIO with a IO$M_WRTATTN mode and have it invoke an AST. This |> AST will set an event flag whenever some process writes into that mailbox. |> The event flag is given as the source for the XtAddInput call. |> |> The problem is that the call back specified in the XtAddInput call never |> gets invoked. I do see during the debugging trace that the event flag |> does get set. |> You need to get a flag from cluster 0 and use that in the first parameter call to XtAddInput. Set this flag in your write-attention AST procedure. While you're in the AST use a dynamically allocated link-list to store your messages with a ptr to the current message. Then in the XtAddInput procedure read in the message and remove it form the list. I do this because the mail handler can handle input faster than the Event handler in X. This should help you get started. Remember though that VMS 5.4 ASTs are not X re-entrant. -- ______________________________________________________________________________ jon@innerdoor.austin.ibm.com * Insert Standard Disclaimer here * IBM Advanced Workstations Division Austin, Texas USA 512-823-5156