In a multi-threaded Python application if one of the threads calls send or recv on a sctp socket, all the threads hang. This is because of the Python GIL (global interpreter lock) not being released by the C module's code.
The issue can be fixed by releasing the lock before the blocking calls to sctp_sendmsg and sctp_recvmsg, patch follows:
In a multi-threaded Python application if one of the threads calls send or recv on a sctp socket, all the threads hang. This is because of the Python GIL (global interpreter lock) not being released by the C module's code.
The issue can be fixed by releasing the lock before the blocking calls to sctp_sendmsg and sctp_recvmsg, patch follows: