ICU does not report Out-Of-Memory (OOM) if it fails to memory map the data file(s) when calling API(s).

Description

When you are using ICU with memory-mapped data file(s), and ICU fails to map the data file due to being out-of-memory, it does not bubble this failure up to the API that was called.

For example:

If memory-mapped data file can't be loaded at all due to being Out-of-memory, then you will get back the error U_MISSING_RESOURCE_ERROR from this API call, rather than U_MEMORY_ALLOCATION_ERROR, which might be a bit surprising to the caller of the API.

This can lead to the application thinking that there are no resources for "en_US" or "en" (or even "root").

If ICU can't load the data file due to being out-of-memory, then it would likely be better to report as such.

Assignee

Jeff Genovy

Reporter

Jeff Genovy

Components

Labels

Reviewer

Andy Heninger

Priority

major

Time Needed

None

Fix versions

Configure