Skip to content

Commit

Permalink
Build with zstd fix
Browse files Browse the repository at this point in the history
  • Loading branch information
linev committed Aug 21, 2024
1 parent 367d1fd commit 7f7a08a
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 6 deletions.
23 changes: 18 additions & 5 deletions build/jsroot.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const version_id = '7.7.x',

/** @summary version date
* @desc Release date in format day/month/year like '14/04/2022' */
version_date = '2/08/2024',
version_date = '21/08/2024',

/** @summary version id and date
* @desc Produced by concatenation of {@link version_id} and {@link version_date}
Expand Down Expand Up @@ -98421,10 +98421,23 @@ async function R__unzip(arr, tgtsize, noalert, src_shift) {
const tgt8arr = new Uint8Array(tgtbuf, fullres);

if (fmt === 'ZSTD') {
const promise = internals._ZstdStream
? Promise.resolve(internals._ZstdStream)
: (isNodeJs() ? Promise.resolve().then(function () { return _rollup_plugin_ignore_empty_module_placeholder$1; }) : Promise.resolve().then(function () { return _rollup_plugin_ignore_empty_module_placeholder$1; }))
.then(({ ZstdInit }) => ZstdInit()).then(({ ZstdStream }) => { internals._ZstdStream = ZstdStream; return ZstdStream; });
let promise;
if (internals._ZstdStream)
promise = Promise.resolve(internals._ZstdStream);
else if (internals._ZstdInit !== undefined)
promise = new Promise(resolveFunc => { internals._ZstdInit.push(resolveFunc); });
else {
internals._ZstdInit = [];
promise = (isNodeJs() ? Promise.resolve().then(function () { return _rollup_plugin_ignore_empty_module_placeholder$1; }) : Promise.resolve().then(function () { return _rollup_plugin_ignore_empty_module_placeholder$1; }))
.then(({ ZstdInit }) => ZstdInit())
.then(({ ZstdStream }) => {
internals._ZstdStream = ZstdStream;
internals._ZstdInit.forEach(func => func(ZstdStream));
delete internals._ZstdInit;
return ZstdStream;
});
}

return promise.then(ZstdStream => {
const data2 = ZstdStream.decompress(uint8arr),
reslen = data2.length;
Expand Down
1 change: 1 addition & 0 deletions changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
## Changes in 7.7.x
1. Fix - correctly handle in I/O empty std::map
2. Fix - reading of small (<1KB) ROOT files
3. Fix - race condition in zstd initialization #318


## Changes in 7.7.2
Expand Down
2 changes: 1 addition & 1 deletion modules/core.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const version_id = '7.7.x',

/** @summary version date
* @desc Release date in format day/month/year like '14/04/2022' */
version_date = '2/08/2024',
version_date = '21/08/2024',

/** @summary version id and date
* @desc Produced by concatenation of {@link version_id} and {@link version_date}
Expand Down

0 comments on commit 7f7a08a

Please sign in to comment.