HRESULT HostNetworkInterface::enableDynamicIPConfig() { #ifndef VBOX_WITH_HOSTNETIF_API return E_NOTIMPL; #else int rc = NetIfEnableDynamicIpConfig(mVirtualBox, this); if (RT_FAILURE(rc)) { LogRel(("Failed to EnableDynamicIpConfig with rc=%Rrc\n", rc)); return rc == VERR_NOT_IMPLEMENTED ? E_NOTIMPL : E_FAIL; } return S_OK; #endif }
STDMETHODIMP HostNetworkInterface::EnableDynamicIpConfig () { #ifndef VBOX_WITH_HOSTNETIF_API return E_NOTIMPL; #else AutoCaller autoCaller(this); if (FAILED(autoCaller.rc())) return autoCaller.rc(); int rc = NetIfEnableDynamicIpConfig(mVBox, this); if (RT_FAILURE(rc)) { LogRel(("Failed to EnableDynamicIpConfig with rc=%Rrc\n", rc)); return rc == VERR_NOT_IMPLEMENTED ? E_NOTIMPL : E_FAIL; } return S_OK; #endif }