static int validateDay( int y, int m, int d )
	{
		if( d > 28 )
		{ // m is 0-based
			if( m == 1 ) // TODO: Get maximum for year
			{
				d = 28;
			}
			else if( ((m == 3) || (m == 5) || (m == 8) || (m == 10)) && (d == 31) )
			{
				d = 30;
			}
		}
		return d;
	}