I'm highly suspicious of running live555 in multiple threads even if you do follow the FAQ. The FAQ basically suggests that you can run 2 independent copies of Live555 in separate threads and those 2 copies can *NOT* interact except via global variables. I don't know for sure but I don't think that is not what Liu is after.

Furthermore I'd be very suspicious of even doing what is suggested in in the FAQ.
I know of at least one place in the code where things could go very wrong:
The RTPInterface.cpp code uses 2 static hash tables when using RTP over TCP. Should you run 2 separate threads of execution of Live555 in the same process both threads would use the same copies of these static hash tables and it would be very easy for them both to try to modify them at the same time or one read while the other is writing and cause those hash tables to be in an inconsistent state and probably cause a crash.

I don't know what other little bombs like this are out there waiting to be discovered.

Matt S.

_______________________________________________
live-devel mailing list
[email protected]
http://lists.live555.com/mailman/listinfo/live-devel

Reply via email to