Commit Graph

18847 Commits

Author SHA1 Message Date
Peter Keresztes Schmidt 627f972fac LocalCamera: Fix Wformat warnings reported by Clang 2021-04-11 18:00:12 +02:00
Isaac Connor f50bfab0aa
Merge pull request #3212 from Carbenium/sdp-deprec
SessionDescriptor: Fix a ffmpeg deprecation warning
2021-04-11 11:53:18 -04:00
Peter Keresztes Schmidt 9f643ddd00 MonitorStream: Actually use the MAX_SLEEP_USEC variable meant for this class 2021-04-11 14:39:08 +02:00
Peter Keresztes Schmidt 2d062c1f99 Fifo+EventStream: Remove unused private fields 2021-04-11 14:26:37 +02:00
Peter Keresztes Schmidt c255e78b97 SessionDescriptor: Fix a ffmpeg deprecation warning
AVStream::codec is deprecated. The replacement AVStream::codecpar is initialized at the end of the method from the codec context.
2021-04-11 11:41:53 +02:00
Peter Keresztes Schmidt 0203e744a5 RtspThread: Fix a stack-buffer-overflow reported by ASAN
==8109==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7fab9b156480 at pc 0x7fabaebef57b bp 0x7fab9b154640 sp 0x7fab9b153df0
READ of size 32 at 0x7fab9b156480 thread T2
    #0 0x7fabaebef57a  (/lib/x86_64-linux-gnu/libasan.so.5+0xb857a)
    #1 0x561c0a9e24eb in bool std::__equal<true>::equal<char>(char const*, char const*, char const*) /usr/include/c++/8/bits/stl_algobase.h:814
    #2 0x561c0a9dfa8e in bool std::__equal_aux<char*, char*>(char*, char*, char*) /usr/include/c++/8/bits/stl_algobase.h:831
    #3 0x561c0a9dd982 in bool std::equal<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >
, __gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >(__gnu_cxx::__normal_iterator<char*,
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, __gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::c
har_traits<char>, std::allocator<char> > >, __gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>
> >) /usr/include/c++/8/bits/stl_algobase.h:1049
    #4 0x561c0a9cf75a in RtspThread::Run() /root/zoneminder/src/zm_rtsp.cpp:411
    #5 0x561c0a9df6e9 in void std::__invoke_impl<void, void (RtspThread::*)(), RtspThread*>(std::__invoke_memfun_deref, void (RtspThread::*&&)(), RtspThread*&
&) /usr/include/c++/8/bits/invoke.h:73
    #6 0x561c0a9dd4ae in std::__invoke_result<void (RtspThread::*)(), RtspThread*>::type std::__invoke<void (RtspThread::*)(), RtspThread*>(void (RtspThread::
*&&)(), RtspThread*&&) (/root/zoneminder/cmake-build-debug-remote/src/zmc+0x1544ae)
    #7 0x561c0a9e6a1a in decltype (__invoke((_S_declval<0ul>)(), (_S_declval<1ul>)())) std:🧵:_Invoker<std::tuple<void (RtspThread::*)(), RtspThread*> >
::_M_invoke<0ul, 1ul>(std::_Index_tuple<0ul, 1ul>) /usr/include/c++/8/thread:244
    #8 0x561c0a9e698d in std:🧵:_Invoker<std::tuple<void (RtspThread::*)(), RtspThread*> >::operator()() /usr/include/c++/8/thread:253
    #9 0x561c0a9e68ff in std:🧵:_State_impl<std:🧵:_Invoker<std::tuple<void (RtspThread::*)(), RtspThread*> > >::_M_run() /usr/include/c++/8/threa
d:196
    #10 0x7fabaca57b2e  (/lib/x86_64-linux-gnu/libstdc++.so.6+0xbbb2e)
    #11 0x7fabae50dfa2 in start_thread /build/glibc-vjB4T1/glibc-2.28/nptl/pthread_create.c:486
    #12 0x7fabac7354ce in clone (/lib/x86_64-linux-gnu/libc.so.6+0xf94ce)
2021-04-11 11:37:03 +02:00
Isaac Connor 8799a33716
Merge pull request #3211 from Carbenium/zm-comms-cleanup
comms: Fix Woverloaded-virtual warnings
2021-04-10 21:24:27 -04:00
Peter Keresztes Schmidt 369fb68bb4 tests/comms: Disable tests which bind TCP sockets on CI runs
Those tests timeout on Cirrus. Disable them for now.
This introduces a new tag [notCI] with which tests can be marked which shouldn't be run during CI.
2021-04-11 02:46:56 +02:00
Peter Keresztes Schmidt 0ab6b04fa1 build: Enable Woverloaded-virtual on GCC 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 0c3244d011 comms/Socket: Mark methods which are not meant to be overridden as non-virtual
This fixes the remaining Woverloaded-virtual warnings.
2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt eacd9d4d36 comms: Add override specifier where necessary 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt f84d23817e tests/comms: Add tests for TcpInetClient/Server 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 3d2614b429 comms: Quick-fix a crash in ZM::Socket::Accept
mLocalAddr is always nullptr and not used anywhere. So just use a local variable for
the time being.
The comms types will need an API rework since the current one is rather convoluted.
Postpone fixing this properly until then.
2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 25e6b70381 tests/comms: Add tests for ZM::UdpUnixSocket 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 17485f3547 tests/comms: Add tests for ZM::UdpInetSocket 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 45986c8ee2 tests/comms: Add some tests for SockAddrInet/Unix 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 5aa508bc74 tests/comms: Add read/write tests for ZM::Pipe 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt a06d374292 tests/comms: Add some basic tests for ZM::Pipe 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt d7224261f7 comms: Implement ZM::Pipe::isClosed so we have a non-abstract class 2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 3b705c15fe build: Store all generated sources in CMAKE_BINARY_DIR
config.h is already generated there so move zm_config_data.h and zm_config_define.h
there as well. Also limit the scope of CMAKE_BINARY_DIR as include directory to the zm target.
All in all this makes zm_config_data and zm_config_define available when building the tests target.
2021-04-11 01:28:23 +02:00
Peter Keresztes Schmidt 7dee86b104 comms: auto-format 2021-04-11 00:23:17 +02:00
Peter Keresztes Schmidt 3011fc3e18 utils: update packpack to current RtspServer commit 2021-04-11 00:22:38 +02:00
Peter Keresztes Schmidt 7c77ac23ba
Merge pull request #3210 from Carbenium/avframe-vector
FifoSource: Adapt to changed xop::AVFrame API
2021-04-11 00:19:38 +02:00
Isaac Connor 64ab6dff95 fix missing ) 2021-04-10 18:16:59 -04:00
Isaac Connor cf721ae875 Merge branch 'release-1.34' of github.com:ZoneMinder/zoneminder into release-1.34 2021-04-10 18:16:17 -04:00
Peter Keresztes Schmidt f8fc768486 FifoSource: Adapt to changed xop::AVFrame API 2021-04-11 00:08:26 +02:00
Isaac Connor 23de612faf update RtspServer 2021-04-10 15:44:44 -04:00
Isaac Connor 4ead6886a3 Make shm debug level 3 2021-04-10 15:40:37 -04:00
Isaac Connor da630f7534 Move shm Memory debug statements to level 2. 2021-04-10 15:35:24 -04:00
Isaac Connor 60970673c7 Implement debug levels in perl side. DEBUG==DEBUG1. 2021-04-10 15:35:04 -04:00
Isaac Connor 3f05cfadb0 update to Rtsp update 2021-04-10 12:21:26 -04:00
Isaac Connor 6319ea887c Need to install generate update script 2021-04-09 21:55:07 -04:00
Isaac Connor 1ccc416224 Merge branch 'release-1.34' 2021-04-09 20:00:47 -04:00
Isaac Connor 35b3d236e0 Fix typo in triggers 2021-04-09 19:47:08 -04:00
Isaac Connor 1ccb8d7aef Include Event Summaries when loading Monitors 2021-04-09 19:46:57 -04:00
Isaac Connor 3dcb71933e Add event summary fields to Monitor Object 2021-04-09 19:46:25 -04:00
Isaac Connor 6f28c16915 Uwse the db queue for event updates 2021-04-09 19:45:55 -04:00
Isaac Connor 08d9ca453a Bump version to 1.35.24 2021-04-09 19:45:23 -04:00
Isaac Connor 2b1e0df6be FIx auth= not getting updated 2021-04-09 18:46:41 -04:00
Isaac Connor 492a352bed Use updated auth_hash when sending alarm requests 2021-04-09 18:33:32 -04:00
Isaac Connor d9dc61265d Fix DisableAlarms. Use signal when capture fails instead of erroneously using TRIGGER_OFF. Add status to DumpSettings so that we can query it with zmu. 2021-04-09 17:46:11 -04:00
Isaac Connor 4e5ef01156 Fixup event summary column population, update triggers 2021-04-09 16:46:36 -04:00
Isaac Connor 3bdd3c0d12 Move event summaries to their own table to reduce contention on Monitor_Status 2021-04-09 10:16:35 -04:00
Isaac Connor c5ca123042 Move event summaries to their own table to reduce contention on Monitor_Status 2021-04-09 10:16:16 -04:00
Isaac Connor 2e22cd5c3b Mark snapshot events as Archived 2021-04-08 15:20:44 -04:00
Isaac Connor 4bd490d121 Set signal=true if capture succeeds. 2021-04-08 11:37:27 -04:00
Andrew Bauer 23bd9d7dc1
update RTSPServer commit hash for packpack 2021-04-08 09:05:01 -05:00
Isaac Connor 2d7479cb59 reintroduce Start() methods to analysis and decoding thread 2021-04-07 20:36:38 -04:00
Isaac Connor 30dfadcbf1 Add some parenthesis and use logic and/or install of binary 2021-04-07 14:15:55 -04:00
Isaac Connor a63186444b Replace char arrays with std::strings in monitor class. 2021-04-07 14:15:55 -04:00