diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2023-02-13 12:50:57 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2023-02-13 12:50:57 +0300 |
commit | 04e101c605cf93642f3ebc837ec0dbcc9b4e93d0 (patch) | |
tree | d3796e85fc308f847dfc1dd032e04d3234c98584 /audio/csound/src/filter/imp.rs | |
parent | 034c0f0fd8f9c87bea0bddf50179cbe5257dfe85 (diff) |
Optimize various error message / debug message formatting
Directly make use of format strings instead of formatting a string
beforehand and then passing it to the macros.
Diffstat (limited to 'audio/csound/src/filter/imp.rs')
-rw-r--r-- | audio/csound/src/filter/imp.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/audio/csound/src/filter/imp.rs b/audio/csound/src/filter/imp.rs index ea0fa4654..6b7a181d0 100644 --- a/audio/csound/src/filter/imp.rs +++ b/audio/csound/src/filter/imp.rs @@ -144,11 +144,11 @@ impl CsoundFilter { if let Some(ref location) = settings.location { csound .compile_csd(location) - .map_err(|e| error_msg!(gst::LibraryError::Failed, [e]))?; + .map_err(|e| error_msg!(gst::LibraryError::Failed, ["{e}"]))?; } else if let Some(ref text) = settings.csd_text { csound .compile_csd_text(text) - .map_err(|e| error_msg!(gst::LibraryError::Failed, [e]))?; + .map_err(|e| error_msg!(gst::LibraryError::Failed, ["{e}"]))?; } else { return Err(error_msg!( gst::LibraryError::Failed, @@ -470,7 +470,7 @@ impl BaseTransformImpl for CsoundFilter { csound.set_score_offset_seconds(settings.offset); if let Err(e) = csound.start() { - return Err(error_msg!(gst::LibraryError::Failed, [e])); + return Err(error_msg!(gst::LibraryError::Failed, ["{e}"])); } Ok(()) |