Fix clippy errors

This commit is contained in:
Igor Katson 2024-12-03 20:40:02 +00:00
parent a728b6666c
commit 438e164ffd
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
15 changed files with 36 additions and 36 deletions

View file

@ -39,7 +39,7 @@ pub struct SsdpMSearchRequest<'a> {
pub st: &'a BStr,
}
impl<'a> SsdpMSearchRequest<'a> {
impl SsdpMSearchRequest<'_> {
fn matches_media_server(&self) -> bool {
if self.man != "\"ssdp:discover\"" {
return false;
@ -81,7 +81,7 @@ pub fn try_parse_ssdp<'a, 'h>(
match (host, man, st) {
(Some(host), Some(man), Some(st)) => {
return Ok(SsdpMessage::MSearch(SsdpMSearchRequest {
Ok(SsdpMessage::MSearch(SsdpMSearchRequest {
host: BStr::new(host),
man: BStr::new(man),
st: BStr::new(st),
@ -90,7 +90,7 @@ pub fn try_parse_ssdp<'a, 'h>(
_ => bail!("not all of host, man and st are set"),
}
}
_ => return Ok(SsdpMessage::OtherRequest(req)),
_ => Ok(SsdpMessage::OtherRequest(req)),
}
}