blob: bae9734afa0d053b1a19fc9f762f0e50385784df (
plain) (
tree)
|
|
The addition is duplicated, causing some dates to be one year off.
Fixes: d43d216feb ("ICU-22633 Test and fix int32_t overflow for Calendar set")
--- source/i18n/islamcal.cpp.old 2024-04-16 16:08:53.000000000 -0500
+++ source/i18n/islamcal.cpp 2024-08-12 00:03:20.102380147 -0500
@@ -452,7 +452,6 @@
// This may be called by Calendar::handleComputeJulianDay with months out of the range
// 0..11. Need to handle that here since monthStart requires months in the range 0.11.
if (month > 11) {
- eyear += (month / 12);
if (uprv_add32_overflow(eyear, (month / 12), &eyear)) {
status = U_ILLEGAL_ARGUMENT_ERROR;
return 0;
|