From: Aurelio Medina <AMedina@xcaliber.com>
To: 'Ross Johnson' <rpj@ise.canberra.edu.au>,
'Le Coent Yannick' <Yannick.LeCoent@srit.siemens.fr>,
pthreads-win32@sourceware.cygnus.com
Subject: RE: Last version of message queues.
Date: Fri, 03 Aug 2001 06:19:00 -0000 [thread overview]
Message-ID: <1BDB01B13696D411BD6200D0B7C854EA01176905@chi-prd-mail1.xcaliber.com> (raw)
Ross,
I am using the 2000-12-29 snapshot. Do you return an error in newer
snapshots. If so, let me know and I can update the code.
Aurelio
-----Original Message-----
From: Ross Johnson [ mailto:rpj@ise.canberra.edu.au ]
Sent: Thursday, August 02, 2001 11:49 PM
To: Aurelio Medina; 'Le Coent Yannick';
pthreads-win32@sourceware.cygnus.com
Subject: Re: Last version of message queues.
Aurelio,
Ross Johnson wrote:
>
> Hi Aurelio,
>
> Last time I looked you needed PTHREAD_PROCESS_SHARED mutexes
> and condition variables. The code you just sent does the same
> as last time.
>
> _POSIX_THREAD_PROCESS_SHARED isn't defined in pthreads-win32, nor
> in Linux I believe (although I could be out of date there).
>
> For example, in mq_open() you have the following code:
>
> if ( (i = pthread_mutexattr_init(&mattr)) != 0)
> goto pthreaderr;
> pthread_mutexattr_setpshared(&mattr, PTHREAD_PROCESS_SHARED);
> i = pthread_mutex_init(&mqhdr->mqh_lock, &mattr);
> pthread_mutexattr_destroy(&mattr); /* be sure to destroy */
> if (i != 0)
> goto pthreaderr;
>
> if ( (i = pthread_condattr_init(&cattr)) != 0)
> goto pthreaderr;
> pthread_condattr_setpshared(&cattr, PTHREAD_PROCESS_SHARED);
> i = pthread_cond_init(&mqhdr->mqh_wait, &cattr);
>
> The *attr_setpshared() calls will be returning ENOSYS errors.
>
I apologise - it's pthread_{mutex,cond}_init() that should be
returning ENOSYS, not *attr_setpshared(). Since you're catching
that I'm now confused so I'll go take a longer harder look.
Sorry.
Ross
next reply other threads:[~2001-08-03 6:19 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-08-03 6:19 Aurelio Medina [this message]
-- strict thread matches above, loose matches on Subject: below --
2001-08-02 7:36 Aurelio Medina
2001-08-02 18:19 ` Ross Johnson
2001-08-02 21:48 ` Ross Johnson
2001-08-02 7:27 Le Coent Yannick
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1BDB01B13696D411BD6200D0B7C854EA01176905@chi-prd-mail1.xcaliber.com \
--to=amedina@xcaliber.com \
--cc=Yannick.LeCoent@srit.siemens.fr \
--cc=pthreads-win32@sourceware.cygnus.com \
--cc=rpj@ise.canberra.edu.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).