Hello All,
We are facing an exception while calling Install method as
below. The exception
says:
"An Exception occurred while trying to run "Shell32.dll,
Control_RunDLL "C:\Program
Files\XFrame\Protocol\xconfig.cpl"" Later it crashes with message
"The instruction at
... referenced memory at ..., Memory could not be read. Click OK to
terminate the
program".
While debugging the following error messages are printed in the Output
window while executing the Install method:
First-chance exception at 0x7c82a36b in rundll32.exe: 0xC0000005:
Access violation reading location 0xfdfdfdfd.
AtlThrow: hr = 0x8007000e
First-chance exception at 0x77e4bee7 in rundll32.exe: Microsoft C++
exception: CMemoryException at memory location 0x0007d47c..
'rundll32.exe': Loaded 'C:\WINDOWS\system32\wshnetbs.dll', No symbols
loaded.
'rundll32.exe': Unloaded 'C:\WINDOWS\system32\wshnetbs.dll'
'rundll32.exe': Loaded 'C:\WINDOWS\system32\wshnetbs.dll', No symbols
loaded.
'rundll32.exe': Unloaded 'C:\WINDOWS\system32\wshnetbs.dll'
'rundll32.exe': Loaded 'C:\WINDOWS\system32\wshnetbs.dll', No symbols
loaded.
'rundll32.exe': Unloaded 'C:\WINDOWS\system32\wshnetbs.dll'
First-chance exception at 0x77e4bee7 in rundll32.exe: 0x000006BA: The
RPC server is unavailable.
First-chance exception at 0x7c82a36b in rundll32.exe: 0xC0000005:
Access violation reading location 0xfdfdfdfd.
First-chance exception at 0x77e4bee7 in rundll32.exe: Microsoft C++
exception: SE_Exception at memory location 0x0007d058..
This worked fine in VS 2003. We have upgraded the projects to VS 2005
after which this
error started occurring.
Can anyone help in solving this problem? Any clues will be
appreciated.
INetCfg * m_pnc;
INetCfgClass *pncNetClass = NULL;
INetCfgClassSetup *pncNetClassSetup = NULL;
INetCfgComponent *pnccMiniport = NULL;
.....
HRESULT hr;
hr = m_pnc->QueryNetCfgClass(&GUID_DEVCLASS_NET,
IID_INetCfgClass,
reinterpret_cast<PPVOID>(&pncNetClass));
if (S_OK == hr)
{
hr = pncNetClass->QueryInterface(IID_INetCfgClassSetup,
reinterpret_cast<PPVOID>(&pncNetClassSetup));
if (S_OK == hr)
{
::CoFreeUnusedLibraries();
PTCHAR ptMiniPortName = Util::GetMiniportName();
hr = pncNetClassSetup->Install(ptMiniPortName,
NULL,
NSF_POSTSYSINSTALL,
0,
NULL,
NULL,
&pnccMiniport );
}
}
With regards,
Phaniram.