Jacek Caban (@jacek) commented about dlls/vbscript/global.c:
+ hres = E_OUTOFMEMORY; + goto done; + } + } + + match_count = 0; + for(i = 0; i < count; i++) { + conv_str = NULL; + if(V_VT(&data[i]) == VT_BSTR) { + str = V_BSTR(&data[i]); + }else { + hres = to_string(&data[i], &conv_str); + if(FAILED(hres)) { + for(i = 0; i < match_count; i++) + SysFreeString(matches[i]); + free(matches); This could be done after `done` label in case of `FAILED(hres)` to simplify error handling.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/10505#note_135673