private void Release() { if (_version != null) { Marshal.ReleaseComObject(_version); _version = null; } if (_versionManager != null) { Marshal.ReleaseComObject(_versionManager); _versionManager = null; } }
private void Release() { if (_version != null) { Marshal.ReleaseComObject(_version); _version = null; } if (_versionManager != null) { Marshal.ReleaseComObject(_versionManager); _versionManager = null; } }
internal IISVersionHelper(string version) { // version is null if we're supposed to use the OS's IIS installation if (version == null) return; try { _versionManager = CreateVersionManager(); _version = _versionManager.GetVersionObject(version, IIS_PRODUCT_EXPRESS); _version.ApplyManifestContext(); } catch { Release(); throw; } }
internal IISVersionHelper(string version) { if (version != null) { try { this._versionManager = CreateVersionManager(); this._version = this._versionManager.GetVersionObject(version, 2); this._version.ApplyManifestContext(); } catch { this.Release(); throw; } } }
internal IISVersionHelper(string version) { if (version != null) { try { this._versionManager = CreateVersionManager(); this._version = this._versionManager.GetVersionObject(version, 2); this._version.ApplyManifestContext(); } catch { this.Release(); throw; } } }
internal IISVersionHelper(string version) { // version is null if we're supposed to use the OS's IIS installation if (version == null) { return; } try { _versionManager = CreateVersionManager(); _version = _versionManager.GetVersionObject(version, IIS_PRODUCT_EXPRESS); _version.ApplyManifestContext(); } catch { Release(); throw; } }