Is there something special in the date 3rd of April 1942? For some reason the the hour of day 0 (12:00 am) is illegal for this specific date. The date is accepted when a lenient calendar is used but the hour of day is incremented to 1 (1:00 am).
Relevant code
java.util.Calendar calendar = java.util.Calendar.getInstance(
java.util.TimeZone.getTimeZone("Europe/Helsinki")
);
calendar.clear();
calendar.setLenient(false);
calendar.set(1942, 3, 3, 0, 0, 0);
calendar.getTimeInMillis();
Exception
java.lang.IllegalArgumentException: HOUR_OF_DAY
at java.util.GregorianCalendar.computeTime(Unknown Source)
at java.util.Calendar.updateTime(Unknown Source)
at java.util.Calendar.getTimeInMillis(Unknown Source)
I'd really prefer is the dates were not lenient as I don't want to accept impossible dates.
-- edit
As the accepted answer and many of the comments pointed out, this does indeed relate to daylight saving. On the 3rd of April 1942 at 00:00 daylight saving was tested in EEST/Helsinki timezone. Currently, daylight savings has been in use since 1981 and the clock is wound forward at 03:00 instead of 00:00. This means that e..g 28th of March 2010 03:00 does no exists in java.util.Calendar.
I'll just have to create a special case for this specific date in my code.