summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2026-04-21 22:00:33 +0200
committerCarl Hetherington <cth@carlh.net>2026-04-21 22:00:33 +0200
commit194561797b00e07e61db611123a7f320819cdb19 (patch)
tree97170cb6f11e9f195fafcb4514deebbed4a3bb40 /src/lib
parent355530d3399d006df06469aab660f565d190cf0a (diff)
Compress an if.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/ffmpeg_audio_stream.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lib/ffmpeg_audio_stream.cc b/src/lib/ffmpeg_audio_stream.cc
index e0da3a22d..f56e04753 100644
--- a/src/lib/ffmpeg_audio_stream.cc
+++ b/src/lib/ffmpeg_audio_stream.cc
@@ -42,8 +42,7 @@ FFmpegAudioStream::FFmpegAudioStream (cxml::ConstNodePtr node, int version)
node->optional_number_child<int>("BitDepth")
)
{
- optional<ContentTime::Type> const f = node->optional_number_child<ContentTime::Type>("FirstAudio");
- if (f) {
+ if (auto f = node->optional_number_child<ContentTime::Type>("FirstAudio")) {
first_audio = ContentTime(f.get());
}
codec_name = node->optional_string_child("CodecName");