diff options
author | Tor Lillqvist <tml@collabora.com> | 2019-04-15 15:53:09 +0300 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-07-25 14:07:22 +0200 |
commit | 6fdd0e22fd87b9ac3345e9356129e55c6a393fd5 (patch) | |
tree | 43223543a6845a565d554a8854026ba359e2be0c /extensions | |
parent | 6451da84ecb2942267a4d0d0bbe3ef45060ef71c (diff) |
Turn an incoming VT_NULL when a STRING is wanted into an empty BSTR
Might help in some cases in the customer application.
Change-Id: Icdc13780d4623e9df8bc057760c1295d7d6ffd61
Reviewed-on: https://gerrit.libreoffice.org/76294
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/source/ole/unoconversionutilities.hxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/extensions/source/ole/unoconversionutilities.hxx b/extensions/source/ole/unoconversionutilities.hxx index 8948de229205..dc023c55c8bb 100644 --- a/extensions/source/ole/unoconversionutilities.hxx +++ b/extensions/source/ole/unoconversionutilities.hxx @@ -433,6 +433,8 @@ void UnoConversionUtilities<T>::variantToAny( const VARIANTARG* pArg, Any& rAny, bFail = true; break; case TypeClass_STRING: // UString + if(var.vt == VT_NULL) + var = CComBSTR(""); if(SUCCEEDED(hr = VariantChangeType( & var, &var, 0, VT_BSTR))) variantToAny( & var, rAny); else if (hr == DISP_E_TYPEMISMATCH) |