| 2045 | } |
| 2046 | |
| 2047 | int RtmpClientStream::Pause(bool pause_or_unpause, double offset_ms) { |
| 2048 | butil::IOBuf req_buf; |
| 2049 | { |
| 2050 | butil::IOBufAsZeroCopyOutputStream zc_stream(&req_buf); |
| 2051 | AMFOutputStream ostream(&zc_stream); |
| 2052 | WriteAMFString(RTMP_AMF0_COMMAND_PAUSE, &ostream); |
| 2053 | WriteAMFUint32(0, &ostream); |
| 2054 | WriteAMFNull(&ostream); |
| 2055 | WriteAMFBool(pause_or_unpause, &ostream); |
| 2056 | WriteAMFNumber(offset_ms, &ostream); |
| 2057 | CHECK(ostream.good()); |
| 2058 | } |
| 2059 | return SendMessage(0, policy::RTMP_MESSAGE_COMMAND_AMF0, req_buf); |
| 2060 | } |
| 2061 | |
| 2062 | void RtmpClientStream::OnStatus(const RtmpInfo& info) { |
| 2063 | if (info.level() == RTMP_INFO_LEVEL_ERROR) { |
nothing calls this directly
no test coverage detected