Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/sdroege/gst-plugin-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2022-04-13 14:26:16 +0300
committerSebastian Dröge <slomo@coaxion.net>2022-04-14 11:14:26 +0300
commite82678586f5a12ceea83d5aee5519a6de3591a30 (patch)
tree8ecf7a5bfc93f47512b5ecbc8ff273ee29e4a6fd /utils/fallbackswitch
parent279dd7d0536a333933361bb6e27773c45d94045c (diff)
fallbackswitch: Remove a redundant pad state unlock/lock
Diffstat (limited to 'utils/fallbackswitch')
-rw-r--r--utils/fallbackswitch/src/fallbackswitch/imp.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/utils/fallbackswitch/src/fallbackswitch/imp.rs b/utils/fallbackswitch/src/fallbackswitch/imp.rs
index 9d106342..b2ae1278 100644
--- a/utils/fallbackswitch/src/fallbackswitch/imp.rs
+++ b/utils/fallbackswitch/src/fallbackswitch/imp.rs
@@ -696,12 +696,11 @@ impl FallbackSwitch {
state
};
- let pad_state = pad_imp.state.lock();
+ let mut pad_state = pad_imp.state.lock();
if pad_state.flushing {
debug!(CAT, obj: element, "Flushing");
return Err(gst::FlowError::Flushing);
}
- drop(pad_state);
let is_active = state.active_sinkpad.as_ref() == Some(pad);
let switched_pad = state.switched_pad;
@@ -753,7 +752,6 @@ impl FallbackSwitch {
state.discont_pending = false;
}
- let mut pad_state = pad_imp.state.lock();
if let Some(running_time) = end_running_time {
pad_state.current_running_time = Some(running_time);
}