mirror of https://github.com/mpv-player/mpv
ao_alsa: cleanup use of vsnprintf
vsnprintf always 0-terminates the string, so remove extra code to do this explicitly. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34841 b3059339-0415-0410-9bf9-f77b7e298cf2 Author: reimar
This commit is contained in:
parent
ca2be52db5
commit
12bab01104
|
@ -83,7 +83,6 @@ static void alsa_error_handler(const char *file, int line, const char *function,
|
||||||
va_start(va, format);
|
va_start(va, format);
|
||||||
vsnprintf(tmp, sizeof tmp, format, va);
|
vsnprintf(tmp, sizeof tmp, format, va);
|
||||||
va_end(va);
|
va_end(va);
|
||||||
tmp[sizeof tmp - 1] = '\0';
|
|
||||||
|
|
||||||
if (err)
|
if (err)
|
||||||
mp_msg(MSGT_AO, MSGL_ERR, "[AO_ALSA] alsa-lib: %s:%i:(%s) %s: %s\n",
|
mp_msg(MSGT_AO, MSGL_ERR, "[AO_ALSA] alsa-lib: %s:%i:(%s) %s: %s\n",
|
||||||
|
|
Loading…
Reference in New Issue