| Index: source/i18n/hebrwcal.cpp
|
| diff --git a/source/i18n/hebrwcal.cpp b/source/i18n/hebrwcal.cpp
|
| index aa16adf988bfe1159b34260e41ef3e863721719c..c5dc4079124384cedd4e3e63b6a3a5141efeb218 100644
|
| --- a/source/i18n/hebrwcal.cpp
|
| +++ b/source/i18n/hebrwcal.cpp
|
| @@ -529,6 +529,13 @@ int32_t HebrewCalendar::handleGetYearLength(int32_t eyear) const {
|
| return startOfYear(eyear+1, status) - startOfYear(eyear, status);
|
| }
|
|
|
| +void HebrewCalendar::validateField(UCalendarDateFields field, UErrorCode &status) {
|
| + if (field == UCAL_MONTH && !isLeapYear(handleGetExtendedYear()) && internalGet(UCAL_MONTH) == ADAR_1) {
|
| + status = U_ILLEGAL_ARGUMENT_ERROR;
|
| + return;
|
| + }
|
| + Calendar::validateField(field, status);
|
| +}
|
| //-------------------------------------------------------------------------
|
| // Functions for converting from milliseconds to field values
|
| //-------------------------------------------------------------------------
|
|
|