From 03f6f4c4c0dec96f8527dcba5cf2f85ff7f2a9ac Mon Sep 17 00:00:00 2001 From: yangkun Date: Fri, 9 Jul 2021 14:58:58 +0800 Subject: [PATCH] fix publish type --- src/Rtmp/RtmpPusher.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Rtmp/RtmpPusher.cpp b/src/Rtmp/RtmpPusher.cpp index 3b0b6c74..9c3567c0 100644 --- a/src/Rtmp/RtmpPusher.cpp +++ b/src/Rtmp/RtmpPusher.cpp @@ -173,9 +173,10 @@ inline void RtmpPusher::send_createStream() { }); } +#define RTMP_STREAM_LIVE "live" inline void RtmpPusher::send_publish() { AMFEncoder enc; - enc << "publish" << ++_send_req_id << nullptr << _stream_id << _app; + enc << "publish" << ++_send_req_id << nullptr << _stream_id << RTMP_STREAM_LIVE; sendRequest(MSG_CMD, enc.data()); addOnStatusCB([this](AMFValue &val) {