summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorBen Boeckel <mathstuf@gmail.com>2018-10-30 21:04:39 -0400
committersfan5 <sfan5@live.de>2018-10-31 09:20:26 +0100
commit6f0ed8e0b2605475850d85608bfa4bbe1bb38a0b (patch)
tree8a7e4da1a98451ec08850b020cb090c75b9e971a /player
parente3e1bdfb135fe3d74d20b94a8191714dc04fb782 (diff)
downloadmpv-6f0ed8e0b2605475850d85608bfa4bbe1bb38a0b.tar.bz2
mpv-6f0ed8e0b2605475850d85608bfa4bbe1bb38a0b.tar.xz
audio: increase a buffer size
The buffer is written to in `audio_config_to_str_buf` using `snprintf` with a `%s` formatting of a 128-byte buffer. This can overflow the target buffer of 80 causing a truncated output.
Diffstat (limited to 'player')
-rw-r--r--player/audio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/player/audio.c b/player/audio.c
index 28e7867ca1..62bc5405f1 100644
--- a/player/audio.c
+++ b/player/audio.c
@@ -403,7 +403,7 @@ static void reinit_audio_filters_and_output(struct MPContext *mpctx)
mp_audio_buffer_reinit_fmt(ao_c->ao_buffer, ao_format, &ao_channels,
ao_rate);
- char tmp[80];
+ char tmp[192];
MP_INFO(mpctx, "AO: [%s] %s\n", ao_get_name(mpctx->ao),
audio_config_to_str_buf(tmp, sizeof(tmp), ao_rate, ao_format,
ao_channels));