diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:43:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:43:14 +0000 |
commit | 8dd16259287f58f9273002717ec4d27e97127719 (patch) | |
tree | 3863e62a53829a84037444beab3abd4ed9dfc7d0 /devtools/server/actors/utils/sources-manager.js | |
parent | Releasing progress-linux version 126.0.1-1~progress7.99u1. (diff) | |
download | firefox-8dd16259287f58f9273002717ec4d27e97127719.tar.xz firefox-8dd16259287f58f9273002717ec4d27e97127719.zip |
Merging upstream version 127.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'devtools/server/actors/utils/sources-manager.js')
-rw-r--r-- | devtools/server/actors/utils/sources-manager.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/devtools/server/actors/utils/sources-manager.js b/devtools/server/actors/utils/sources-manager.js index fda37a3184..981a7c8213 100644 --- a/devtools/server/actors/utils/sources-manager.js +++ b/devtools/server/actors/utils/sources-manager.js @@ -101,7 +101,8 @@ class SourcesManager extends EventEmitter { this._thread.threadLifetimePool.manage(actor); this._sourceActors.set(source, actor); - if (this._sourcesByInternalSourceId && source.id) { + // source.id can be 0 for WASM sources + if (this._sourcesByInternalSourceId && Number.isInteger(source.id)) { this._sourcesByInternalSourceId.set(source.id, source); } @@ -157,7 +158,8 @@ class SourcesManager extends EventEmitter { if (!this._sourcesByInternalSourceId) { this._sourcesByInternalSourceId = new Map(); for (const source of this._thread.dbg.findSources()) { - if (source.id) { + // source.id can be 0 for WASM sources + if (Number.isInteger(source.id)) { this._sourcesByInternalSourceId.set(source.id, source); } } |