From: Aaron Robinson Date: Wed, 31 May 2023 22:11:00 +0000 (-0700) Subject: Clean-up error in `IDispatch::Invoke()` scenario (#86964) X-Git-Tag: accepted/tizen/unified/riscv/20231226.055536~1893 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=872facc9697e5eed9ad43a787f38c07b35b5eee3;p=platform%2Fupstream%2Fdotnet%2Fruntime.git Clean-up error in `IDispatch::Invoke()` scenario (#86964) * Clean-up error in IDispatch::Invoke scenario --- diff --git a/src/coreclr/inc/corerror.xml b/src/coreclr/inc/corerror.xml index afeaf4f602a..81c7bab5ea1 100644 --- a/src/coreclr/inc/corerror.xml +++ b/src/coreclr/inc/corerror.xml @@ -1603,7 +1603,7 @@ COR_E_TARGET "Attempt to invoke non-static method with a null Object." - - If you attempt to invoke a non-static method with a null Object - If you atte + If you attempt to invoke a non-static method with a null Object diff --git a/src/coreclr/vm/interoputil.cpp b/src/coreclr/vm/interoputil.cpp index 65710a5227b..d2dc577b30c 100644 --- a/src/coreclr/vm/interoputil.cpp +++ b/src/coreclr/vm/interoputil.cpp @@ -3114,7 +3114,7 @@ void IUInvokeDispMethod( // Validate that the target is valid for the specified type. if (!IsComTargetValidForType(pRefClassObj, pTarget)) - COMPlusThrow(kTargetException, W("RFLCT.Targ_ITargMismatch")); + COMPlusThrow(kTargetException, W("RFLCT_Targ_ITargMismatch")); // If the invoked type is an interface, make sure it is IDispatch based. if (pInvokedMT->IsInterface()) diff --git a/src/coreclr/vm/invokeutil.cpp b/src/coreclr/vm/invokeutil.cpp index ea2278e73e3..c4ba804a4c4 100644 --- a/src/coreclr/vm/invokeutil.cpp +++ b/src/coreclr/vm/invokeutil.cpp @@ -681,7 +681,7 @@ void InvokeUtil::ValidateObjectTarget(FieldDesc *pField, TypeHandle enclosingTyp return; if (!pField->IsStatic() && !*target) - COMPlusThrow(kTargetException,W("RFLCT.Targ_StatFldReqTarg")); + COMPlusThrow(kTargetException,W("RFLCT_Targ_StatFldReqTarg")); // Verify that the object is of the proper type... TypeHandle ty = (*target)->GetTypeHandle();