mf/tests: Fix incorrect array index when formatting blob value.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45988
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47084
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=49715
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=52183
Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Rémi Bernon 2022-03-29 11:55:27 +02:00 committed by Alexandre Julliard
parent 8516a9e931
commit edef14126c
1 changed files with 1 additions and 1 deletions

View File

@ -147,7 +147,7 @@ static void check_attributes_(int line, IMFAttributes *attributes, const struct
case VT_VECTOR | VT_UI1:
buf += sprintf(buf, "size %lu, data {", value.caub.cElems);
for (j = 0; j < 16 && j < value.caub.cElems; ++j)
buf += sprintf(buf, "0x%02x,", value.caub.pElems[i + j]);
buf += sprintf(buf, "0x%02x,", value.caub.pElems[j]);
if (value.caub.cElems > 16)
buf += sprintf(buf, "...}");
else