Skip to content

Commit ee64691

Browse files
authored
Merge pull request #2387 from retailcoder/next
Vbe.Interop.Forms dependency fix, and don't iterate references+components in protected projects when releasing
2 parents f81f17a + e4483de commit ee64691

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

RetailCoder.VBE/Rubberduck.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,7 @@
247247
<SpecificVersion>False</SpecificVersion>
248248
<EmbedInteropTypes>False</EmbedInteropTypes>
249249
<HintPath>..\libs\Microsoft.Vbe.Interop.Forms.dll</HintPath>
250+
<Private>True</Private>
250251
</Reference>
251252
<Reference Include="Ninject.Extensions.Conventions">
252253
<HintPath>..\packages\ninject.extensions.conventions.3.2.0.0\lib\net45-full\Ninject.Extensions.Conventions.dll</HintPath>

Rubberduck.VBEEditor/Rubberduck.VBEditor.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@
105105
<SpecificVersion>False</SpecificVersion>
106106
<EmbedInteropTypes>False</EmbedInteropTypes>
107107
<HintPath>..\libs\Microsoft.Vbe.Interop.Forms.dll</HintPath>
108+
<Private>True</Private>
108109
</Reference>
109110
<Reference Include="office">
110111
<HintPath>..\libs\Office.dll</HintPath>

Rubberduck.VBEEditor/SafeComWrappers/VBA/VBProject.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,11 @@ public override void Release(bool final = false)
117117
{
118118
if (!IsWrappingNullReference)
119119
{
120-
References.Release();
121-
VBComponents.Release();
120+
if (Protection == ProjectProtection.Unprotected)
121+
{
122+
References.Release();
123+
VBComponents.Release();
124+
}
122125
base.Release(final);
123126
}
124127
}

0 commit comments

Comments
 (0)