@@ -11278,7 +11278,6 @@ class ClrStackImpl
11278
11278
static void PrintArgsAndLocals (IXCLRDataStackWalk *pStackWalk, BOOL bArgs, BOOL bLocals)
11279
11279
{
11280
11280
ToRelease<IXCLRDataFrame> pFrame;
11281
- ToRelease<IXCLRDataValue> pVal;
11282
11281
ULONG32 argCount = 0 ;
11283
11282
ULONG32 localCount = 0 ;
11284
11283
HRESULT hr = S_OK;
@@ -11290,14 +11289,14 @@ class ClrStackImpl
11290
11289
hr = pFrame->GetNumArguments (&argCount);
11291
11290
11292
11291
if (SUCCEEDED (hr) && bArgs)
11293
- hr = ShowArgs (argCount, pFrame, pVal );
11292
+ hr = ShowArgs (argCount, pFrame);
11294
11293
11295
11294
// Print locals
11296
11295
if (SUCCEEDED (hr) && bLocals)
11297
11296
hr = pFrame->GetNumLocalVariables (&localCount);
11298
11297
11299
11298
if (SUCCEEDED (hr) && bLocals)
11300
- ShowLocals (localCount, pFrame, pVal );
11299
+ ShowLocals (localCount, pFrame);
11301
11300
11302
11301
ExtOut (" \n " );
11303
11302
}
@@ -11308,9 +11307,8 @@ class ClrStackImpl
11308
11307
* Params:
11309
11308
* argy - the number of arguments the function has
11310
11309
* pFramey - the frame we are inspecting
11311
- * pVal - a pointer to the CLRDataValue we use to query for info about the args
11312
11310
*/
11313
- static HRESULT ShowArgs (ULONG32 argy, IXCLRDataFrame *pFramey, IXCLRDataValue *pVal )
11311
+ static HRESULT ShowArgs (ULONG32 argy, IXCLRDataFrame *pFramey)
11314
11312
{
11315
11313
CLRDATA_ADDRESS addr = 0 ;
11316
11314
BOOL fPrintedLocation = FALSE ;
@@ -11332,6 +11330,7 @@ class ClrStackImpl
11332
11330
ExtOut (" PARAMETERS:\n " );
11333
11331
}
11334
11332
11333
+ ToRelease<IXCLRDataValue> pVal;
11335
11334
hr = pFramey->GetArgumentByIndex (i,
11336
11335
&pVal,
11337
11336
mdNameLen,
@@ -11413,8 +11412,6 @@ class ClrStackImpl
11413
11412
{
11414
11413
ExtOut (" <no data>\n " );
11415
11414
}
11416
-
11417
- pVal->Release ();
11418
11415
}
11419
11416
11420
11417
return S_OK;
@@ -11425,9 +11422,8 @@ class ClrStackImpl
11425
11422
* Params:
11426
11423
* localy - the number of locals in the frame
11427
11424
* pFramey - the frame we are inspecting
11428
- * pVal - a pointer to the CLRDataValue we use to query for info about the args
11429
11425
*/
11430
- static HRESULT ShowLocals (ULONG32 localy, IXCLRDataFrame *pFramey, IXCLRDataValue *pVal )
11426
+ static HRESULT ShowLocals (ULONG32 localy, IXCLRDataFrame *pFramey)
11431
11427
{
11432
11428
for (ULONG32 i=0 ; i < localy; i++)
11433
11429
{
@@ -11438,6 +11434,7 @@ class ClrStackImpl
11438
11434
ExtOut (" " );
11439
11435
11440
11436
// local names don't work in Whidbey.
11437
+ ToRelease<IXCLRDataValue> pVal;
11441
11438
hr = pFramey->GetLocalVariableByIndex (i, &pVal, mdNameLen, NULL , g_mdName);
11442
11439
if (FAILED (hr))
11443
11440
{
@@ -11506,8 +11503,6 @@ class ClrStackImpl
11506
11503
{
11507
11504
ExtOut (" <no data>\n " );
11508
11505
}
11509
-
11510
- pVal->Release ();
11511
11506
}
11512
11507
11513
11508
return S_OK;
0 commit comments