delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/06/20/20:28:17

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <3B30CDF1.2020800@ece.gatech.edu>
Date: Wed, 20 Jun 2001 12:23:13 -0400
From: "Charles S. Wilson" <cwilson AT ece DOT gatech DOT edu>
User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; m18) Gecko/20010131 Netscape6/6.01
X-Accept-Language: en
MIME-Version: 1.0
To: Brian Michael Genisio <genisiob AT pilot DOT msu DOT edu>
CC: cygwin AT sources DOT redhat DOT com
Subject: Re: cygipc does not seem to work!!!
References: <200106191932 DOT f5JJWm532232 AT pilot14 DOT cl DOT msu DOT edu>

Note that Brian has already contacted me (as the cygipc maintainer) -- 
but I'm at a loss.  So I referred him here.  It looks like an 
ownership/permissions problem, but I really don't understand the 
underlying windows IPC mechanisms on which cygipc was based, so I'm not 
sure about how permissions are handled.  (I didn't write cygipc; I just 
saved it from death on the net and put in on my web page).

Here's a thought: Brian, you're not using the '--tight-security' option 
with the background ipc-daemon process, are you?

--Chuck

Brian Michael Genisio wrote:

> Hello Cygwin people,
> 
> I am trying to get a very simple shared memory application to work.  It works
> find in linux and solaris, but in cygwin... no luck.
> 
> I create the memory and attach to it with :
> shmid = shmget(IPC_PRIVATE, 100, IPC_CREAT|0777);
> strp = (char *)shmat(shmid, 0, 0);
> 
> The other app gets the shmid through stdout, and through a command arg.  It
> opens it with :
> strp = (char *)shmat(shmid, 0, 0);
> 
> The problem is that the second application cannot open the shared memory until
> the first application has terminated!!!  Once it does, it can read the memory
> with no problem.  Unfortunately, it is difficult for them to communicate when
> the first program has already exited.
> 
> I have tested it by starting the creator program, and running ipcs.  ipcs does
> not recognize the memory either, until the program has exited.
> 
> Any ideas?  Has anyone else gotten it to work?  Shared memory isnt that
> difficult... and I am not sure why I am having this problem.
> 
> Thanks,
> Brian
> 
> 
> 
> 
> 
> --
> ---------------------------
>       \\|//   Brian Genisio
>       (o o)        genisiob AT pilot DOT msu DOT edu
> ~~oOOo~(_)~oOOo~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> 
> 
> 
> 
> --
> Want to unsubscribe from this list?
> Check out: http://cygwin.com/ml/#unsubscribe-simple


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019