projects
/
rust-lightning
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a7c7c34
)
f - Warn about calling features() in a hot code path
author
Jeffrey Czyz
<jkczyz@gmail.com>
Mon, 31 Jan 2022 23:23:49 +0000
(17:23 -0600)
committer
Jeffrey Czyz
<jkczyz@gmail.com>
Mon, 31 Jan 2022 23:23:49 +0000
(17:23 -0600)
lightning/src/routing/router.rs
patch
|
blob
|
history
diff --git
a/lightning/src/routing/router.rs
b/lightning/src/routing/router.rs
index b1e24627d9e0c06fa4901088e12a069524b474d6..08f499fb751837bf4ef4921897e8227325cc84e3 100644
(file)
--- a/
lightning/src/routing/router.rs
+++ b/
lightning/src/routing/router.rs
@@
-373,6
+373,7
@@
impl<'a> CandidateRouteHop<'a> {
}
}
+ // NOTE: This may copy bytes to so avoid calling it in a hot code path.
fn features(&self) -> ChannelFeatures {
match self {
CandidateRouteHop::FirstHop { details } => details.counterparty.features.to_context(),