diff options
author | wm4 <wm4@nowhere> | 2020-04-09 11:27:38 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2020-04-09 11:27:38 +0200 |
commit | bc1a18ee245ec2243d4b7b0fa22894f4326b3758 (patch) | |
tree | f8b56c493a058c17bb64ae5b3b77b77003d5d0be /demux | |
parent | 823e5205eac66e5bff0953605b5b6c9ddde54739 (diff) | |
download | mpv-bc1a18ee245ec2243d4b7b0fa22894f4326b3758.tar.bz2 mpv-bc1a18ee245ec2243d4b7b0fa22894f4326b3758.tar.xz |
options: cleanup .min use for OPT_CHANNELS
Replace use of .min==1 with a proper flag. This is a good idea, because
it has nothing to do with numeric limits (also see commit 9d32d62b61547
for how this can go wrong).
With this, m_option.min/max are strictly used for numeric limits.
Diffstat (limited to 'demux')
-rw-r--r-- | demux/demux_raw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/demux/demux_raw.c b/demux/demux_raw.c index e606a24c9f..edc89e7418 100644 --- a/demux/demux_raw.c +++ b/demux/demux_raw.c @@ -54,7 +54,7 @@ struct demux_rawaudio_opts { #define OPT_BASE_STRUCT struct demux_rawaudio_opts const struct m_sub_options demux_rawaudio_conf = { .opts = (const m_option_t[]) { - {"channels", OPT_CHANNELS(channels), .min = 1}, + {"channels", OPT_CHANNELS(channels), .flags = M_OPT_CHANNELS_LIMITED}, {"rate", OPT_INT(samplerate), M_RANGE(1000, 8 * 48000)}, {"format", OPT_CHOICE(aformat, {"u8", PCM(0, 0, 8, 0)}, |