Lines Matching refs:pNetCfg
59 static HRESULT vboxNetCfgWinINetCfgLock(IN INetCfg *pNetCfg,
65 HRESULT hr = pNetCfg->QueryInterface(IID_INetCfgLock, (PVOID*)&pLock);
86 static HRESULT vboxNetCfgWinINetCfgUnlock(IN INetCfg *pNetCfg)
89 HRESULT hr = pNetCfg->QueryInterface(IID_INetCfgLock, (PVOID*)&pLock);
110 INetCfg *pNetCfg;
111 HRESULT hr = CoCreateInstance(CLSID_CNetCfg, NULL, CLSCTX_INPROC_SERVER, IID_INetCfg, (PVOID*)&pNetCfg);
120 hr = vboxNetCfgWinINetCfgLock(pNetCfg, pszwClientDescription, cmsTimeout, ppszwClientDescription);
130 hr = pNetCfg->Initialize(NULL);
133 *ppNetCfg = pNetCfg;
140 pNetCfg->Release();
144 VBOXNETCFGWIN_DECL(HRESULT) VBoxNetCfgWinReleaseINetCfg(IN INetCfg *pNetCfg, IN BOOL fHasWriteLock)
146 if (!pNetCfg) /* If network config has been released already, just bail out. */
152 HRESULT hr = pNetCfg->Uninitialize();
161 HRESULT hr2 = vboxNetCfgWinINetCfgUnlock(pNetCfg);
168 pNetCfg->Release();
240 static HRESULT vboxNetCfgWinQueryInstaller(IN INetCfg *pNetCfg, IN const GUID *pguidClass, INetCfgClassSetup **ppSetup)
242 HRESULT hr = pNetCfg->QueryNetCfgClass(pguidClass, IID_INetCfgClassSetup, (void**)ppSetup);
248 VBOXNETCFGWIN_DECL(HRESULT) VBoxNetCfgWinInstallComponent(IN INetCfg *pNetCfg, IN LPCWSTR pszwComponentId, IN const GUID *pguidClass,
252 HRESULT hr = vboxNetCfgWinQueryInstaller(pNetCfg, pguidClass, &pSetup);
272 HRESULT tmpHr = pNetCfg->Apply();
284 static HRESULT vboxNetCfgWinInstallInfAndComponent(IN INetCfg *pNetCfg, IN LPCWSTR pszwComponentId, IN const GUID *pguidClass,
306 hr = VBoxNetCfgWinInstallComponent(pNetCfg, pszwComponentId, pguidClass, ppComponent);
331 VBOXNETCFGWIN_DECL(HRESULT) VBoxNetCfgWinUninstallComponent(IN INetCfg *pNetCfg, IN INetCfgComponent *pComponent)
342 hr = vboxNetCfgWinQueryInstaller(pNetCfg, &GuidClass, &pSetup);
356 hr = pNetCfg->Apply();
368 typedef BOOL (*VBOXNETCFGWIN_NETCFGENUM_CALLBACK) (IN INetCfg *pNetCfg, IN INetCfgComponent *pNetCfgComponent, PVOID pContext);
370 static HRESULT vboxNetCfgWinEnumNetCfgComponents(IN INetCfg *pNetCfg,
376 HRESULT hr = pNetCfg->EnumComponents(pguidClass, &pEnumComponent);
393 fResult = callback(pNetCfg, pNetCfgComponent, pContext);
3012 INetCfg *pNetCfg = NULL;
3014 hr = VBoxNetCfgWinQueryINetCfg(&pNetCfg, TRUE, L"VirtualBox Host-Only Creation",
3020 hr = vboxNetCfgWinEnumNetCfgComponents(pNetCfg,
3026 hr = vboxNetCfgWinEnumNetCfgComponents(pNetCfg,
3031 hr = vboxNetCfgWinEnumNetCfgComponents(pNetCfg,
3039 hr = pNetCfg->Apply();
3043 VBoxNetCfgWinReleaseINetCfg(pNetCfg, TRUE);