Remove unnecessary assert. (dotnet/coreclr#7889)
authorJim Ma <mazong1123@gmail.com>
Sat, 29 Oct 2016 17:47:15 +0000 (01:47 +0800)
committerJan Kotas <jkotas@microsoft.com>
Sat, 29 Oct 2016 17:47:15 +0000 (10:47 -0700)
Remvoe the unneccessary assert that might cause a bug.

fix dotnet/coreclr#6856

Commit migrated from https://github.com/dotnet/coreclr/commit/d64c7d60fcc8132c8a57c5c3c9d6e296232520dd

src/coreclr/src/vm/commodule.cpp

index 44a96d3..af6dc48 100644 (file)
@@ -768,8 +768,7 @@ mdString QCALLTYPE COMModule::GetStringConstant(QCall::ModuleHandle pModule, LPC
     _ASSERTE(pwzValue != NULL);
 
     HRESULT hr = pRCW->GetEmitter()->DefineUserString(pwzValue, iLength, &strRef);
-    if (FAILED(hr)) {   
-        _ASSERTE(hr == E_OUTOFMEMORY || !"Unknown failure in DefineUserString");    
+    if (FAILED(hr)) { 
         COMPlusThrowHR(hr);    
     }