horgh / videostreamer

Stream video (e.g. RTSP) to an HTML5 video element (MP4)
GNU General Public License v3.0
267 stars 60 forks source link

Resolve out-of-bounds issues with packet writing #7

Closed rbisewski closed 6 years ago

rbisewski commented 6 years ago

I noticed a number of out-of-bounds errors present when running your videostreamer alongside valgrind / gdb. As a result, I have added a number of safety checks and functionality is kept the same while fewer errors occur. Several TODOs were added as well since I think more testing might be required to guarantee that this code is safe in threaded environments.

Feel free to test it on your side to ensure this works and let me know what you think.

rbisewski commented 6 years ago

As per our discussion, I think the solution you added to the races branch yesterday solved the main issue to a certain degree. In any event the code itself could use more focused testing, so to keep it simple in that case I think I can just close this more generic pull request. If I discover another issue I can just can just create a dedicated issue for that specific problem. Thanks again :)