On 08/16/2012 02:16 PM, Martin Storsjö wrote:
> On Thu, 16 Aug 2012, Samuel Pitoiset wrote:
>
>> Some strict servers like crtmpserver returns an error when the specified
>> stream is not found in call to releaseStream.
>> ---
>> libavformat/rtmpproto.c | 7 ++++---
>> 1 file changed, 4 insertions(+), 3 deletions(-)
>>
>> diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c
>> index db11501..49b7e19 100644
>> --- a/libavformat/rtmpproto.c
>> +++ b/libavformat/rtmpproto.c
>> @@ -398,7 +398,7 @@ static int gen_release_stream(URLContext *s,
>> RTMPContext *rt)
>> ff_amf_write_null(&p);
>> ff_amf_write_string(&p, rt->playpath);
>>
>> - return rtmp_send_packet(rt, &pkt, 0);
>> + return rtmp_send_packet(rt, &pkt, 1);
>> }
>>
>> /**
>> @@ -1257,8 +1257,9 @@ static int handle_invoke_error(URLContext *s,
>> RTMPPacket *pkt)
>>
>> if (!ff_amf_get_field_value(pkt->data + 9, data_end,
>> "description", tmpstr, sizeof(tmpstr))) {
>> - if (tracked_method && !strcmp(tracked_method, "_checkbw")) {
>> - /* Ignore _checkbw errors. */
>> + if (tracked_method && (!strcmp(tracked_method, "_checkbw") ||
>> + !strcmp(tracked_method,
>> "releaseStream"))) {
>> + /* Ignore _checkbw and releaseStream errors. */
>> level = AV_LOG_WARNING;
>> ret = 0;
>> } else
>> --
>> 1.7.11.3
>
> Looks good to me. Luca mentioned that there were some other methods as
> well that we should ignore errors for (FCSubscribe, or was it
> FCPublish?), it might be good to fix them all at once.
both, you can have rtmp servers with clustering unimplemented.
lu
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel