判断消息是否为 SIP 请求
(msg: &str)
| 578 | if content_length.is_some_and(|existing| existing != parsed) { |
| 579 | return SipFrameResult::Invalid; |
| 580 | } |
| 581 | content_length = Some(parsed); |
| 582 | } |
| 583 | } |
| 584 | |
| 585 | let Some(total_length) = headers_with_separator.checked_add(content_length.unwrap_or(0)) else { |
| 586 | return SipFrameResult::Invalid; |
| 587 | }; |
| 588 | |
| 589 | // 检查缓冲区中是否有足够的数据 |
no outgoing calls
no test coverage detected