FreeBSD/contrib/ntp/libntp/ntp_calendar.c
/*
 *---------------------------------------------------------------------
 * For a given RD, get the RD of the associated year start,
 * that is, the RD of the last January,1st on or before that day.
 *---------------------------------------------------------------------
 */
For a given RD, get the RD of the associated year start,
that is, the RD of the last January,1st on or before that day.
For a given RD get the RD of the associated year start that is the RD of the last January 1st on or before that day .
int32_t
ntpcal_rd_to_ystart(
	int32_t rd
	)
{
	return rd - ntpcal_split_eradays(rd - 1, NULL).lo;
}
int32_t ntpcal_rd_to_ystart ( int32_t rd ) { return rd - ntpcal_split_eradays ( rd - 1 , NULL ) . lo ; }
For a given RD, get the RD of the associated year start,
 that is, the RD of the last January,1st on or before that day.
For a given RD get the RD of the associated year start that is the RD of the last January 1st on or before that day .
/*
	 * Rather simple exercise: split the day number into elapsed
	 * years and elapsed days, then remove the elapsed days from the
	 * input value. Nice'n sweet...
	 */