Isaac Connor
40e8b81143
fix: multiple issues in zm_rtsp_server_fifo_source
...
- Fix inverted logic in ReadRun(): was returning when NOT stopping,
now correctly returns when stopping or terminating
- Remove redundant "1 and" condition in WriteRun NAL size check
- Add input validation for content length parsing using strtoul
with bounds checking to prevent overflow/invalid data issues
- Store m_rtspServer by value instead of reference to prevent
potential dangling reference if original shared_ptr changes
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com >
2026-01-30 14:49:53 -05:00
Isaac Connor
d0bde9882b
On reload, need to actually close the fd so that we can reopen it
2026-01-29 17:30:32 -05:00
Aaron Kling
c4683d90a9
Format code using astyle google format
...
Commands used:
astyle --style=google --indent=spaces=2 --keep-one-line-blocks src/*.cpp
astyle --style=google --indent=spaces=2 --keep-one-line-blocks src/*.h
2024-03-26 13:43:58 -05:00
Isaac Connor
7517de2811
Add some more debugging. Include zm_terminate in while loop condition. return instead of continuing to process nals if _stop or _zmterminate
2024-02-13 16:34:01 -05:00
Isaac Connor
a62b32f2e4
Include fifo name in debug
2023-07-21 14:10:46 -04:00
Doug Nazar
3b21153757
Fix various printf formats for 32bit, 32bit w/_FILE_OFFSET_BITS=64 and 64-bit
2022-07-16 03:18:18 -04:00
Isaac Connor
ed4704438b
Handle zmTerminate in ReadRun. Fixes crash on termination of zm_rtsp_server
2022-06-17 10:36:35 -04:00
Isaac Connor
838704e58e
Add more stop_ tests so that when we are told to terminate, we actually do so.
2022-02-03 11:40:17 -05:00
Isaac Connor
85d5dd806e
Read 4k at a time instead of 32 bytes. OS will read whatever is available. This basically reduces logging and a little cpu overhead
2021-08-05 13:30:52 -04:00
Isaac Connor
c2f4d65860
Turn down debugging
2021-06-13 14:08:51 -04:00
Isaac Connor
0bcb30b8a9
Don't print out buffer since it isn't zero terminated
2021-05-31 10:19:58 -04:00
Isaac Connor
3cd9bdccd5
style and performance improvements reported by cppcheck
2021-05-09 16:39:38 -04:00
Peter Keresztes Schmidt
68bedfe48f
Fix logging format string mismatches
...
* Remove SZFMTD format macro and use %zu instead for size_t. %zu is understood by every compiler nowadays.
2021-04-30 00:26:24 +02:00
Isaac Connor
968bdc5abe
Correct nal count reporting
2021-04-17 12:50:26 -04:00
Isaac Connor
d0a390b42f
decrease logging of nal counts
2021-03-26 08:15:55 -04:00
Isaac Connor
7038263e3b
implement a nal splitter for udp transmission
2021-03-25 13:12:52 -04:00
Isaac Connor
e5a464f090
fix reverse logic on testing stop_
2021-03-23 13:53:07 -04:00
Isaac Connor
456afac0ec
Must initialize stop_
2021-03-23 10:07:55 -04:00
Isaac Connor
8bc22880a4
use modern threads. Add a separate thread for sending data.
2021-03-22 17:49:59 -04:00
Isaac Connor
feafaa29bf
improve debug logging
2021-03-17 12:49:12 -04:00
Isaac Connor
b1f6eb127b
Switch from live555 to PHZ76/RtspServer
2021-03-10 11:01:04 -05:00
Isaac Connor
ebd29a3cb9
use the timeout version of read_into so that we don't stay blocked while we have been told to exit. If getNextFrame returns -1 sleep for a second.
2021-03-05 14:18:12 -05:00
Isaac Connor
7da1e48456
Fix delete=>delete[] on header. If we read_into the buffer more all our pointers can be invalidated. So use offsets instead
2021-03-04 13:26:10 -05:00
Isaac Connor
1c40145e89
not finding space for pts is debug now and show the contents of header
2021-03-02 12:41:26 -05:00
Isaac Connor
d33540c962
Fix logic on clearing frame queue
2021-03-01 16:49:27 -05:00
Isaac Connor
53851b67c7
use a Buffer to implement the simple ZM header protocol for passing packet data from ZM to RTSP Server
2021-03-01 16:49:27 -05:00
Isaac Connor
fdf1fbd497
Add a fifo version of the rtsp server
2021-03-01 16:46:48 -05:00