diff options
author | uau <uau@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-11-01 06:52:44 +0000 |
---|---|---|
committer | uau <uau@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-11-01 06:52:44 +0000 |
commit | e803711bbd6fab43214d166d5064a7f19154b8b6 (patch) | |
tree | b7243f0a7dc3182c28e2d4549a4c4a6c1852b019 /libaf | |
parent | ff1568af58598b4b0a2463981fa8da2dce348a79 (diff) | |
download | mpv-e803711bbd6fab43214d166d5064a7f19154b8b6.tar.bz2 mpv-e803711bbd6fab43214d166d5064a7f19154b8b6.tar.xz |
af_scaletempo: Fix crash in option parsing
The value of the "speed" suboption was not initialized before calling
subopt_parse(). If the command line had suboptions but "speed" was not
one of them then the code accessed an uninitialized pointer and
possibly crashed. Fixed by initializing the option value.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24926 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libaf')
-rw-r--r-- | libaf/af_scaletempo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libaf/af_scaletempo.c b/libaf/af_scaletempo.c index b25e8413e8..8e117b2a17 100644 --- a/libaf/af_scaletempo.c +++ b/libaf/af_scaletempo.c @@ -434,7 +434,7 @@ static int control(struct af_instance_s* af, int cmd, void* arg) *(float*)arg = s->scale; return AF_OK; case AF_CONTROL_COMMAND_LINE:{ - strarg_t speed; + strarg_t speed = {}; opt_t subopts[] = { {"scale", OPT_ARG_FLOAT, &s->scale_nominal, NULL}, {"stride", OPT_ARG_FLOAT, &s->ms_stride, NULL}, |