On 3/12/2014 19:36, Jactry Zeng wrote: > I made this leak, sorry.. :( > "What goes around comes around" was confirmed! :p > VariantInit(&testfile); > V_VT(&testfile) = VT_BSTR; > V_BSTR(&testfile) = SysAllocString(filename); No need for VariantInit() here. > + SysFreeString(V_BSTR(&testfile)); It's cleaner to use VariantClear().