Skip to content

Commit 4c1532f

Browse files
Merge pull request #309 from jamesc-skyward/master
Cancel project build if any project is canceled
2 parents efc7a7c + 6e89e36 commit 4c1532f

File tree

1 file changed

+6
-8
lines changed
  • src/toolkit/Community.VisualStudio.Toolkit.Shared/Build

1 file changed

+6
-8
lines changed

src/toolkit/Community.VisualStudio.Toolkit.Shared/Build/Build.cs

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -169,18 +169,16 @@ public int UpdateProjectCfg_Done(IVsHierarchy pHierProj, IVsCfg pCfgProj, IVsCfg
169169
{
170170
if (_hierarchy is not null)
171171
{
172+
if (fCancel != 0)
173+
{
174+
_result.SetCanceled();
175+
}
176+
172177
// We are observing the build of a specific project. If the project
173178
// that finished is the one we are observing, then we can set the result.
174179
if (pHierProj == _hierarchy)
175180
{
176-
if (fCancel != 0)
177-
{
178-
_result.SetCanceled();
179-
}
180-
else
181-
{
182-
_result.SetResult(fSuccess != 0);
183-
}
181+
_result.SetResult(fSuccess != 0);
184182
}
185183
}
186184

0 commit comments

Comments
 (0)