[zeromq-dev] multiple contexts on multiple processes and mailbox.ccp:84 assertion

Pedro Melo melo at simplicidade.org
Wed Aug 22 01:46:03 CEST 2012


On Tue, Aug 21, 2012 at 8:49 PM, Ian Barber <ian.barber at gmail.com> wrote:
> On Tue, Aug 21, 2012 at 1:32 PM, Pedro Melo <melo at simplicidade.org> wrote:
>> Is there a clean way to do this, have fork()'s after the context was created?
> It's tricky! You'd do better creating a context for each child to be honest.

Yeah, I've come to understand this, but this is an old code base and I
can't change that on this particular case.

I was able to generate a small C program that I can use to trigger the
assertion. I can reproduce it now, and it gave me some insights on how
to go about working around it. The C program is here:


Basically, if a child process calls zmq_term on the parents context,
the assertion will be triggered on the parent.

Pedro Melo
xmpp:melo at simplicidade.org
mailto:melo at simplicidade.org

More information about the zeromq-dev mailing list