Improve the locking.
Improve the locking.

Thanks to Tolya Korniltsev for reporting the issue and
testing the fix.

sctplab/usrsctp,sctplab/usrsctp,weinrank/usrsctp,sctplab/usrsctp,weinrank/usrsctp,weinrank/usrsctp