internal int InternalGetDaysInMonth(int year, int month) {
int nDays;
int mask; // mask for extracting bits
mask = 0x8000;
// convert the lunar day into a lunar month/date
mask >>= (month-1);
if ((GetYearInfo(year, nDaysPerMonth) & mask)== 0)
nDays = 29;
else
nDays = 30;
return nDays;
}