Skip to content

Commit 7941b9c

Browse files
authored
fix: a shot in the dark at fixing the "Mutex double-freed" error (#39)
* a shot in the dark at fixing the "Mutex double-freed" error * skip MS Edge for now since it is not launching
1 parent 9ba035c commit 7941b9c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

azure-pipelines.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
BUNDLESIZE_GITHUB_TOKEN: $(BUNDLESIZE_GITHUB_TOKEN)
2525
SAUCE_ACCESS_KEY: $(SAUCE_ACCESS_KEY)
2626
SAUCE_USERNAME: $(SAUCE_USERNAME)
27-
TEST_BROWSERS: 'ChromeHeadlessNoSandbox,FirefoxHeadless,sl_edge,sl_ios_safari,sl_android_chrome'
27+
TEST_BROWSERS: 'ChromeHeadlessNoSandbox,FirefoxHeadless,sl_ios_safari,sl_android_chrome'
2828

2929
- task: PublishTestResults@2
3030
displayName: 'Save test results'

src/PromisifiedFS.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ module.exports = class PromisifiedFS {
6969
// but there might not be any other fs operations needed until later. Therefore we
7070
// need to attempt to release the mutex
7171
this._activate().then(() => {
72-
if (this._operations.size === 0) {
72+
if (this._operations.size === 0 && !this._deactivationTimeout) {
7373
this._deactivationTimeout = setTimeout(this._deactivate.bind(this), 100)
7474
}
7575
})
@@ -89,6 +89,7 @@ module.exports = class PromisifiedFS {
8989
this._operations.delete(op)
9090
if (mutating) this.saveSuperblock() // this is debounced
9191
if (this._operations.size === 0) {
92+
if (!this._deactivationTimeout) clearTimeout(this._deactivationTimeout)
9293
this._deactivationTimeout = setTimeout(this._deactivate.bind(this), 500)
9394
}
9495
}

0 commit comments

Comments
 (0)