Article View: comp.soft-sys.andrew
Article #1776Re: message queue with ATK
From: Zalman Stern
Date: Tue, 17 Nov 1992 23:46
Date: Tue, 17 Nov 1992 23:46
34 lines
2023 bytes
2023 bytes
In article <1992Nov17.163509.662@csi.uottawa.ca> isabelle@shamin.genie.uottawa.ca (Isabelle Tourneux) writes: > > I would like to use message queues with ATK and ADEW. > > - is it possible to use the usual msgrcv and msgsnd in an > infinite loop ? I have tried to put an infinite loop in the > "controller_go" of an Adew view-controller, but it disturbs the > usual functionnning of the controller. > > - does an object-oriented function (a sort of "im_AddMessageQueue") > exist to set an input handler when something arrives on a > message queue, just as it does for sockets in im_AddFileHandler ? > > In short, is there a way I can use message queues, or can I use > only sockets to communicate with other processes ? > > Thanks > > Isabelle Tourneux > Multimedia Lab of the University of Ottawa, > isabelle@shamin.genie.uottawa.ca The namespace for System V message queues is disjoint from the file descriptor namespace. They do not work with select and hence do not fit into ATK interaction model. In short the SysV message and shared memory interfaces are evil crud which never should have been implemented in a UNIX kernel. Use the BSD send and recv calls instead. Or if you have SysVr4, you might try putmsg and getmsg on streams but I'm not sure how that stuff interacts with select. (And it undoubtedly depends on the particular version of UNIX you are running.) -- Zalman Stern zalman@adobe.com (415) 962 3824 Adobe Systems, 1585 Charleston Rd., POB 7900, Mountain View, CA 94039-7900 "Yeah. Ask 'em if they'll upgrade my shifters too." Bill Watterson
Technical Details
Message-ID:
<1992Nov17.234622.5623@adobe.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!gumby!wupost!decwrl!adobe!usenetReferences:
<1992Nov17.163509.662@csi.uottawa.ca>Show Full Headers
Complete Article Headers
Newsgroups: comp.soft-sys.andrew Path: arc1-ca.pugleaf.net!sparky!uunet!gumby!wupost!decwrl!adobe!usenet From: zstern@adobe.com (Zalman Stern) Subject: Re: message queue with ATK Message-ID: <1992Nov17.234622.5623@adobe.com> Sender: usenet@adobe.com (USENET NEWS) Organization: Adobe Systems Incorporated References: <1992Nov17.163509.662@csi.uottawa.ca> Date: Tue, 17 Nov 1992 23:46:22 GMT Lines: 34