From 8fef006fd232d0ffab5fc4efb4a6cb4fdec60117 Mon Sep 17 00:00:00 2001 From: Mike McCormack Date: Sat, 18 Aug 2001 16:06:30 +0000 Subject: [PATCH] Implemented oleaut32.VarBstrCat. --- dlls/oleaut32/oleaut32.spec | 2 +- dlls/oleaut32/variant.c | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/dlls/oleaut32/oleaut32.spec b/dlls/oleaut32/oleaut32.spec index 2bb7f1873bc..deeb2232fff 100644 --- a/dlls/oleaut32/oleaut32.spec +++ b/dlls/oleaut32/oleaut32.spec @@ -317,7 +317,7 @@ debug_channels (ole typelib) 436 stub VarAbs # stdcall (ptr ptr) 437 stub VarAdd # stdcall (ptr ptr ptr) 438 stub VarAnd # stdcall (ptr ptr ptr) -439 stub VarBstrCat # stdcall (ptr ptr ptr) +439 stdcall VarBstrCat(ptr ptr ptr) VarBstrCat 440 stdcall VarBstrCmp(ptr ptr long long) VarBstrCmp 441 stub VarCat # stdcall (ptr ptr ptr) 442 stub VarCmp # stdcall (ptr ptr long long) diff --git a/dlls/oleaut32/variant.c b/dlls/oleaut32/variant.c index 86d20bc25a2..c15331b3eae 100644 --- a/dlls/oleaut32/variant.c +++ b/dlls/oleaut32/variant.c @@ -4672,3 +4672,23 @@ HRESULT WINAPI VarBstrCmp(BSTR left, BSTR right, LCID lcid, DWORD flags) return VARCMP_EQ; } +/********************************************************************** + * VarBstrCat [OLEAUT32.439] + */ +HRESULT WINAPI VarBstrCat(BSTR left, BSTR right, BSTR *out) +{ + BSTR result; + + TRACE("( %s %s %p )\n", debugstr_w(left), debugstr_w(right), out); + + if( (!left) || (!right) || (!out) ) + return 0; + + result = SysAllocStringLen(left, lstrlenW(left)+lstrlenW(right)); + lstrcatW(result,right); + + *out = result; + + return 1; +} +