fix rtsp compiling warning. v7.0.91 (#4504)
## steps to produce: 1. ./configure --rtsp=off 2. make --------- Co-authored-by: winlin <winlinvip@gmail.com>
This commit is contained in:
parent
20f6cd595c
commit
f4c54ab9a5
|
|
@ -7,6 +7,7 @@ The changelog for SRS.
|
||||||
<a name="v7-changes"></a>
|
<a name="v7-changes"></a>
|
||||||
|
|
||||||
## SRS 7.0 Changelog
|
## SRS 7.0 Changelog
|
||||||
|
* v7.0, 2025-09-20, Merge [#4504](https://github.com/ossrs/srs/pull/4504): fix rtsp compiling warning. v7.0.91 (#4504)
|
||||||
* v7.0, 2025-09-19, Merge [#4503](https://github.com/ossrs/srs/pull/4503): AI: Refine RTMP/SRT/RTC bridge. v7.0.90 (#4503)
|
* v7.0, 2025-09-19, Merge [#4503](https://github.com/ossrs/srs/pull/4503): AI: Refine RTMP/SRT/RTC bridge. v7.0.90 (#4503)
|
||||||
* v7.0, 2025-09-15, RTC2RTMP: Fix sequence number wraparound assertion crashes. v7.0.89 (#4491)
|
* v7.0, 2025-09-15, RTC2RTMP: Fix sequence number wraparound assertion crashes. v7.0.89 (#4491)
|
||||||
* v7.0, 2025-09-14, Merge [#4489](https://github.com/ossrs/srs/pull/4489): Improve coverage for kernel. v7.0.88 (#4489)
|
* v7.0, 2025-09-14, Merge [#4489](https://github.com/ossrs/srs/pull/4489): Improve coverage for kernel. v7.0.88 (#4489)
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,6 @@
|
||||||
|
|
||||||
#include <srs_core.hpp>
|
#include <srs_core.hpp>
|
||||||
|
|
||||||
#include <inttypes.h>
|
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,6 @@
|
||||||
#endif
|
#endif
|
||||||
#include <srs_app_rtc_source.hpp>
|
#include <srs_app_rtc_source.hpp>
|
||||||
|
|
||||||
#include <vector>
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
ISrsFrameTarget::ISrsFrameTarget()
|
ISrsFrameTarget::ISrsFrameTarget()
|
||||||
|
|
@ -61,9 +60,9 @@ SrsRtmpBridge::SrsRtmpBridge()
|
||||||
#endif
|
#endif
|
||||||
#ifdef SRS_RTSP
|
#ifdef SRS_RTSP
|
||||||
rtsp_builder_ = NULL;
|
rtsp_builder_ = NULL;
|
||||||
|
rtsp_target_ = NULL;
|
||||||
#endif
|
#endif
|
||||||
rtc_target_ = NULL;
|
rtc_target_ = NULL;
|
||||||
rtsp_target_ = NULL;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SrsRtmpBridge::~SrsRtmpBridge()
|
SrsRtmpBridge::~SrsRtmpBridge()
|
||||||
|
|
@ -73,14 +72,24 @@ SrsRtmpBridge::~SrsRtmpBridge()
|
||||||
#endif
|
#endif
|
||||||
#ifdef SRS_RTSP
|
#ifdef SRS_RTSP
|
||||||
srs_freep(rtsp_builder_);
|
srs_freep(rtsp_builder_);
|
||||||
|
rtsp_target_ = NULL;
|
||||||
#endif
|
#endif
|
||||||
rtc_target_ = NULL;
|
rtc_target_ = NULL;
|
||||||
rtsp_target_ = NULL;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool SrsRtmpBridge::empty()
|
bool SrsRtmpBridge::empty()
|
||||||
{
|
{
|
||||||
return !rtc_target_.get() || !rtsp_target_.get();
|
if (rtc_target_.get()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef SRS_RTSP
|
||||||
|
if (rtsp_target_.get()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SrsRtmpBridge::enable_rtmp2rtc(SrsSharedPtr<SrsRtcSource> rtc_source)
|
void SrsRtmpBridge::enable_rtmp2rtc(SrsSharedPtr<SrsRtcSource> rtc_source)
|
||||||
|
|
@ -88,10 +97,12 @@ void SrsRtmpBridge::enable_rtmp2rtc(SrsSharedPtr<SrsRtcSource> rtc_source)
|
||||||
rtc_target_ = rtc_source;
|
rtc_target_ = rtc_source;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef SRS_RTSP
|
||||||
void SrsRtmpBridge::enable_rtmp2rtsp(SrsSharedPtr<SrsRtspSource> rtsp_source)
|
void SrsRtmpBridge::enable_rtmp2rtsp(SrsSharedPtr<SrsRtspSource> rtsp_source)
|
||||||
{
|
{
|
||||||
rtsp_target_ = rtsp_source;
|
rtsp_target_ = rtsp_source;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
srs_error_t SrsRtmpBridge::initialize(ISrsRequest *r)
|
srs_error_t SrsRtmpBridge::initialize(ISrsRequest *r)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -12,8 +12,6 @@
|
||||||
#include <srs_core_autofree.hpp>
|
#include <srs_core_autofree.hpp>
|
||||||
#include <srs_kernel_codec.hpp>
|
#include <srs_kernel_codec.hpp>
|
||||||
|
|
||||||
#include <vector>
|
|
||||||
|
|
||||||
class ISrsRequest;
|
class ISrsRequest;
|
||||||
class SrsMediaPacket;
|
class SrsMediaPacket;
|
||||||
class SrsLiveSource;
|
class SrsLiveSource;
|
||||||
|
|
@ -22,8 +20,10 @@ class SrsRtmpFormat;
|
||||||
class SrsMetaCache;
|
class SrsMetaCache;
|
||||||
class SrsRtpPacket;
|
class SrsRtpPacket;
|
||||||
class SrsRtcRtpBuilder;
|
class SrsRtcRtpBuilder;
|
||||||
|
#ifdef SRS_RTSP
|
||||||
class SrsRtspSource;
|
class SrsRtspSource;
|
||||||
class SrsRtspRtpBuilder;
|
class SrsRtspRtpBuilder;
|
||||||
|
#endif
|
||||||
class SrsRtcFrameBuilder;
|
class SrsRtcFrameBuilder;
|
||||||
class ISrsStreamBridge;
|
class ISrsStreamBridge;
|
||||||
class SrsSrtFrameBuilder;
|
class SrsSrtFrameBuilder;
|
||||||
|
|
@ -94,7 +94,9 @@ private:
|
||||||
#endif
|
#endif
|
||||||
// The Source bridge, bridge stream to other source.
|
// The Source bridge, bridge stream to other source.
|
||||||
SrsSharedPtr<SrsRtcSource> rtc_target_;
|
SrsSharedPtr<SrsRtcSource> rtc_target_;
|
||||||
|
#ifdef SRS_RTSP
|
||||||
SrsSharedPtr<SrsRtspSource> rtsp_target_;
|
SrsSharedPtr<SrsRtspSource> rtsp_target_;
|
||||||
|
#endif
|
||||||
|
|
||||||
public:
|
public:
|
||||||
SrsRtmpBridge();
|
SrsRtmpBridge();
|
||||||
|
|
@ -103,7 +105,9 @@ public:
|
||||||
public:
|
public:
|
||||||
bool empty();
|
bool empty();
|
||||||
void enable_rtmp2rtc(SrsSharedPtr<SrsRtcSource> rtc_source);
|
void enable_rtmp2rtc(SrsSharedPtr<SrsRtcSource> rtc_source);
|
||||||
|
#ifdef SRS_RTSP
|
||||||
void enable_rtmp2rtsp(SrsSharedPtr<SrsRtspSource> rtsp_source);
|
void enable_rtmp2rtsp(SrsSharedPtr<SrsRtspSource> rtsp_source);
|
||||||
|
#endif
|
||||||
|
|
||||||
public:
|
public:
|
||||||
virtual srs_error_t initialize(ISrsRequest *r);
|
virtual srs_error_t initialize(ISrsRequest *r);
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,6 @@
|
||||||
|
|
||||||
#define VERSION_MAJOR 7
|
#define VERSION_MAJOR 7
|
||||||
#define VERSION_MINOR 0
|
#define VERSION_MINOR 0
|
||||||
#define VERSION_REVISION 90
|
#define VERSION_REVISION 91
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
Loading…
Reference in New Issue
Block a user