From 54ef0bbfd239c365dbaea5bac512fe5d3dfabab3 Mon Sep 17 00:00:00 2001 From: Jaakko Laitinen Date: Tue, 31 Mar 2020 16:39:56 +0300 Subject: [PATCH] Fix unintended functionality when giving multiple --pu-depth-intra/inter list parameters --- src/cfg.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/cfg.c b/src/cfg.c index 7434d7a0..f6950304 100644 --- a/src/cfg.c +++ b/src/cfg.c @@ -326,6 +326,10 @@ static int parse_pu_depth_list( const char *array, int32_t *depths_min, int32_t int len = strlen( list ); int retval = 1; + //Reset depths in case multiple pu depth parameters are given + memset( depths_max, -1, size * sizeof( *depths_max ) ); + memset( depths_min, -1, size * sizeof( *depths_min ) ); + token = strtok( list, "," ); while( ptr < len && list[ptr + 1] == ',' ) {