Skip to content

Commit

Permalink
net/rabbiteer: Fix build with rust 1.76.0
Browse files Browse the repository at this point in the history
Import upstream patch [1] to fix the following error:

error[E0310]: the parameter type `T` may not live long enough
    --> /wrkdirs/usr/ports/net/rabbiteer/work/rabbiteer-rs-c881238/cargo-crates/rustc-serialize-0.3.24/src/serialize.rs:1155:5

[1] rust-lang-deprecated/rustc-serialize@75ce924

PR:		276920
Approved by:	portmgr (build fix blanket)
  • Loading branch information
MikaelUrankar committed Feb 19, 2024
1 parent 5461083 commit 2e82ac5
Showing 1 changed file with 13 additions and 0 deletions.
@@ -0,0 +1,13 @@
https://github.com/rust-lang-deprecated/rustc-serialize/commit/75ce92452a5f7c25a58fdea81e5f6f888630a2c9

--- cargo-crates/rustc-serialize-0.3.24/src/serialize.rs.orig 2024-02-10 11:58:37 UTC
+++ cargo-crates/rustc-serialize-0.3.24/src/serialize.rs
@@ -1152,7 +1152,7 @@ impl<'a, T: ?Sized> Decodable for Cow<'a, T>
where T: ToOwned, T::Owned: Decodable
{
#[inline]
- fn decode<D: Decoder>(d: &mut D) -> Result<Cow<'static, T>, D::Error> {
+ fn decode<D: Decoder>(d: &mut D) -> Result<Cow<'a, T>, D::Error> {
Ok(Cow::Owned(try!(Decodable::decode(d))))
}
}

0 comments on commit 2e82ac5

Please sign in to comment.