Skip to content

Commit 4eb7004

Browse files
committed
lock file
1 parent 5bec0e0 commit 4eb7004

4 files changed

Lines changed: 7 additions & 1875 deletions

File tree

src/NetCore2Blockly/NetCore2Blockly/GenerateBlocklyFilesHostedService.cs

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -691,10 +691,14 @@ internal void registerCallback()
691691
cp.GetChangeToken().RegisterChangeCallback(a =>
692692
{
693693

694-
695694
var s = a as GenerateBlocklyFilesHostedService;
696-
s.DoWork(null);
697-
s.registerCallback();
695+
if (s == null)
696+
return;
697+
lock (s)
698+
{
699+
s.DoWork(null);
700+
s.registerCallback();
701+
}
698702
}, this);
699703

700704
}
-5.37 KB
Binary file not shown.
-91.2 KB
Binary file not shown.

0 commit comments

Comments
 (0)