diff --git a/src/rtsp/BasicRTSPOnlyServer.cpp b/src/rtsp/BasicRTSPOnlyServer.cpp index 684f78810..bd8698a9f 100644 --- a/src/rtsp/BasicRTSPOnlyServer.cpp +++ b/src/rtsp/BasicRTSPOnlyServer.cpp @@ -43,6 +43,7 @@ */ #include // for "weHaveAnIPv*Address()" +#include #include "rtsp/BasicRTSPOnlyServer.hh" #include "rtsp/BasicRTSPOnlySubsession.hh" @@ -87,10 +88,9 @@ BasicRTSPOnlyServer::getInstance(){ int BasicRTSPOnlyServer::init_server() { - if (env != NULL || rtspServer != NULL || mod == NULL || - avType <= none || avType > rtsp_av_type_last) { - exit(1); - } + assert(env == nullptr && rtspServer == nullptr); + assert(mod != nullptr); + assert(avType > none && avType <= rtsp_av_type_last); //setting livenessTimeoutTask unsigned reclamationTestSeconds = 60;