Skip to content

Commit 75808d5

Browse files
authored
fix deadlock on unknown policy request (#7606)
Signed-off-by: Mikhail Kot <to@myrrc.dev>
1 parent e06e371 commit 75808d5

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

vortex-session/src/lib.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,9 @@ impl VortexSession {
7272

7373
/// Returns whether unknown plugins should deserialize as foreign placeholders.
7474
pub fn allows_unknown(&self) -> bool {
75-
<Self as SessionExt>::get::<UnknownPluginPolicy>(self).allow_unknown
75+
<Self as SessionExt>::get_opt::<UnknownPluginPolicy>(self)
76+
.map(|p| p.allow_unknown)
77+
.unwrap_or(false)
7678
}
7779
}
7880

0 commit comments

Comments
 (0)