The deadlock is caused by the different order of mutex locks during
inputPort->disconnect(outputPort); // input port mutex locked, output port mutex locked
and
outputPort->write(pkt); // output port mutex locked, input port mutex locked.
The bug can be reproduced in the toolchain-2.10 branch, example to reproduce the issue:
The deadlock is caused by the different order of mutex locks during inputPort->disconnect(outputPort); // input port mutex locked, output port mutex locked and outputPort->write(pkt); // output port mutex locked, input port mutex locked.
The bug can be reproduced in the toolchain-2.10 branch, example to reproduce the issue: