Avoid enums containing references with lifetimes
[rust-lightning] / lightning / src / ln / channelmanager.rs
index cdeb2c4d16e6fdf40a2a172916e78545f2969073..03ac4ba52722e5d9958972fa5a9ce35313415a25 100644 (file)
@@ -3086,7 +3086,7 @@ where
                // If we returned an error and the `node_signer` cannot provide a signature for whatever
                // reason`, we wouldn't be able to receive inbound payments through the corresponding
                // channel.
-               let sig = self.node_signer.sign_gossip_message(msgs::UnsignedGossipMessage::ChannelUpdate(&unsigned)).unwrap();
+               let sig = self.node_signer.sign_gossip_message(msgs::UnsignedGossipMessage::ChannelUpdate(unsigned.clone())).unwrap();
 
                Ok(msgs::ChannelUpdate {
                        signature: sig,