From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00,INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!tut.cis.ohio-state.edu!ucbvax!dog.ee.lbl.gov!ucsd!hub.ucsb.edu!vega!spinrad From: spinrad@vega.ucsb.edu Newsgroups: comp.lang.ada Subject: HELP: Ada an socket system calls Summary: gettting EINTR - Interrupted system call Keywords: socket system verdix sun Message-ID: <10168@hub.ucsb.edu> Date: 23 Mar 91 08:31:43 GMT Sender: news@hub.ucsb.edu List-Id: Hello Ada Wizards, I'm new to ada and to sockets so if this problem has already been dealt with, I apologize. I'm tryinng to implement an ada program which runs concurrently on 2 (or more) sun 3/60s. I've set up unix stream sockets to communicate between the programs running on different computers, and for single task ada programs, I got the sockets working perfectly. To implement the socket system calls, I used 'C' routines which I linked to ada via the INTERFACE pragmas. As I mentioned earlier, I got this part working fine for single task ada programs. But when I try to use additional ada tasks, my SEND and RECV socket system calls occasionally return with errno = EINTR - Interrupted system call In my simple test program which runs into this error I have two tasks: 1 task continually makes c interface calls which results in a SEND system call; the other task is in an infinite loop adding and subtracting a fixed amount to a variable. My guess that the EINTR is caused by a signal from the os used by ada to implement task switching. And I'm guessing that this signal occasionally arrives while one of the tasks in a socket system call. Has anybody seen something like this before, or am I in newly unexplored territory? If someone has seen this error in ada before, can you tell me if my guesses are correct, and how did you get around this problem? Any suggestions or insights would be grately appreciated. If possible I would perfer replies be sent by email instead of posted to the newsgroup. If there is a large interest I'll post a summary. And one final note, I'm using the VERDIX ada compiler on sun 3/60s. Many Thanks!!! Sandy -- Sandy Spinrad Internet: spinrad@cornu.ucsb.edu UUNET: uunet!hub.ucsb.edu!spinrad@cornu