瀏覽代碼

win-wasapi: Fix PROPVARIANT variable has not be freed

Chensiyy 2 年之前
父節點
當前提交
54568cb3bd
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      plugins/win-wasapi/enum-wasapi.cpp

+ 1 - 0
plugins/win-wasapi/enum-wasapi.cpp

@@ -30,6 +30,7 @@ string GetDeviceName(IMMDevice *device)
 			device_name.resize(size);
 			os_wcs_to_utf8(nameVar.pwszVal, len, &device_name[0],
 				       size);
+			PropVariantClear(&nameVar);
 		}
 	}