Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
deps: backport ICU-20558 to fix Intl crasher
- Floating patch for ICU 63.x and 64.x
- fixing crash in Intl when ICU data not found.
- Regression test from refack included.

Background:
- ICU-13778 (landed in ICU 63.1) fixed a bug but
added a regression.
- a recent v8 land in Node v12 (which one?) exposes
this bug to cause a crash when ICU data is not found.

ICU Bug: https://unicode-org.atlassian.net/browse/ICU-20558
Backport of: unicode-org/icu#632
(Commit not landed yet in ICU)
Fixes: #27379
Co-authored-by: Refael Ackermann <[email protected]>
  • Loading branch information
srl295 and refack committed Apr 25, 2019
commit c369ef018f30c896168bfb8f9babd3e84fbdcd57
8 changes: 8 additions & 0 deletions test/parallel/test-intl.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'use strict';
const common = require('../common');
const assert = require('assert');
const { execFile } = require('child_process');

// Does node think that i18n was enabled?
let enablei18n = process.config.variables.v8_enable_i18n_support;
Expand Down Expand Up @@ -125,4 +126,11 @@ if (!common.hasIntl) {
assert.strictEqual(coll.compare('Bluebird', 'bluebird'), 0);
// `ffi` ligature (contraction)
assert.strictEqual(coll.compare('\ufb03', 'ffi'), 0);

// Regression test for https://github.com/nodejs/node/issues/27379
execFile(
process.execPath, ['-p', 'new Date().toLocaleString()'],
{ env: { LC_ALL: 'ja' }, encoding: 'utf-8' },
common.mustCall((e) => assert.ifError(e))
);
}
Loading