winlin

fix protocol decode PCUC packet bug, requires 4bytes

@@ -2632,7 +2632,7 @@ int SrsUserControlPacket::decode(SrsStream* stream) @@ -2632,7 +2632,7 @@ int SrsUserControlPacket::decode(SrsStream* stream)
2632 event_data = stream->read_4bytes(); 2632 event_data = stream->read_4bytes();
2633 2633
2634 if (event_type == SrcPCUCSetBufferLength) { 2634 if (event_type == SrcPCUCSetBufferLength) {
2635 - if (!stream->require(2)) { 2635 + if (!stream->require(4)) {
2636 ret = ERROR_RTMP_MESSAGE_ENCODE; 2636 ret = ERROR_RTMP_MESSAGE_ENCODE;
2637 srs_error("decode user control packet failed. ret=%d", ret); 2637 srs_error("decode user control packet failed. ret=%d", ret);
2638 return ret; 2638 return ret;