Fix tester_v3_c base-dir split on Windows paths

parse_path_for_test() split the file path on '/' only, so a Windows
style arg like models\Cube\Cube.gltf produced an empty base dir and
external buffers (Cube.bin) failed to resolve. Split on '\' too.
This commit is contained in:
Syoyo Fujita
2026-07-31 22:13:14 +09:00
parent 9b56d2f600
commit b30be77ad7

View File

@@ -1409,6 +1409,7 @@ static int parse_path_for_test(tg3_model *model, tg3_error_stack *errors,
}
slash = strrchr(path, '/');
if (!slash) slash = strrchr(path, '\\');
base_len = slash ? (uint32_t)(slash - path) : 0;
err = tg3_parse_auto(model, errors, buf, (uint64_t)sz, path, base_len, opts);
free(buf);