home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!crdgw1!rpi!usc!sdd.hp.com!saimiri.primate.wisc.edu!ames!decwrl!pa.dec.com!engage.pko.dec.com!nntpd.lkg.dec.com!e2big.mko.dec.com!adserv.enet.dec.com!winalski
- From: winalski@adserv.enet.dec.com (Paul S. Winalski)
- Newsgroups: comp.os.vms
- Subject: Re: Mailbox access
- Message-ID: <1993Jan27.234319.15802@e2big.mko.dec.com>
- Date: 27 Jan 93 23:43:19 GMT
- References: <20303.2b5bb282@ul.ie>
- Sender: usenet@e2big.mko.dec.com (Mr. USENET)
- Reply-To: winalski@adserv.enet.dec.com (Paul S. Winalski)
- Organization: Digital Equipment Corporation, Nashua NH
- Lines: 38
-
-
- In article <20303.2b5bb282@ul.ie>, 9120092@ul.ie writes:
- |>
- |>So far I can create mailboxes and pass data
- |>to a subprocess of my account but can not do the same to a mailbox in
- |>another account. This is primerily caused by VMS which takes a mailboxes
- |>name and places the pointer to that device in the PCB. So when a mailbox
- |>is created instead of being "My-Mailbox" and being open for group
- |>access it is infact "My-PID.My-Mailbox" which tends to throw a spanner
- |>in the works for me as I can not get around that protection.
- |>I think IO$Write_Attention gets involved some where but I'm not sure.
- |>Am I right about the mailbox protection. any suggestions on getting
- |>around it?
-
- IO$_WRITEATTN doesn't enter into it at all.
-
- You haven't told us exactly what fails when you try to run your application
- from another user account. Your analysis above is completely wrong. There
- are no pointers to any devices (let alone mailboxes) in the PCB for a
- process.
-
- What does happen is that the $CREMBX service creates logical names for
- temporary mailboxes in the LNM$TEMPORARY_MAILBOX logical name table.
- Normally, LNM$TEMPORARY_MAILBOX is defined to point to LNM$JOB, your process's
- job logical name table. Thus, if you use $CREMBX to create a mailbox and
- assign logical name XXX to the mailbox, the XXX logical name is defined in
- LNM$JOB, and therefore only visible to your login process and all of its
- subprocesses. If you try to open the mailbox from another process, not in
- the same job, using the logical name, it will fail because that process
- cannot see the logical name. One way to get around this is to use the
- physical device name for the mailbox rather than the logical name. You
- can find the physical device name by doing a $GETDVI call on the channel that
- was returned by $CREMBX, asking for the physical device name. Then you can
- use whatever means you wish to communicate that device name to the other
- process (such as defining a group-wide or system-wide logical name, or writing
- it to a file that the other process opens and reads, or whatever.
-
- --PSW
-