function write_dos_date(buf, date) {
	if(typeof date === "string") date = new Date(date);
	var hms = date.getHours();
	hms = hms << 6 | date.getMinutes();
	hms = hms << 5 | (date.getSeconds()>>>1);
	buf.write_shift(2, hms);
	var ymd = (date.getFullYear() - 1980);
	ymd = ymd << 4 | (date.getMonth()+1);
	ymd = ymd << 5 | date.getDate();
	buf.write_shift(2, ymd);
}
function write_dos_date(buf, date) {
	if(typeof date === "string") date = new Date(date);
	var hms = date.getHours();
	hms = hms << 6 | date.getMinutes();
	hms = hms << 5 | (date.getSeconds()>>>1);
	buf.write_shift(2, hms);
	var ymd = (date.getFullYear() - 1980);
	ymd = ymd << 4 | (date.getMonth()+1);
	ymd = ymd << 5 | date.getDate();
	buf.write_shift(2, ymd);
}
function write_dos_date ( buf , date ) { if ( typeof date === "string" ) date = new Date ( date ) ; var hms = date . getHours ( ) ; hms = hms << 6 | date . getMinutes ( ) ; hms = hms << 5 | ( date . getSeconds ( ) >>> 1 ) ; buf . write_shift ( 2 , hms ) ; var ymd = ( date . getFullYear ( ) - 1980 ) ; ymd = ymd << 4 | ( date . getMonth ( ) + 1 ) ; ymd = ymd << 5 | date . getDate ( ) ; buf . write_shift ( 2 , ymd ) ; }
/* -------------------------------------------------------------------------- /* DOS Date format:
high|YYYYYYYm.mmmddddd.HHHHHMMM.MMMSSSSS|low
add 1980 to stored year
stored second should be doubled
 /* write JS date to buf as a DOS date
/ * -------------------------------------------------------------------------- / * DOS Date format : high|YYYYYYYm . mmmddddd . HHHHHMMM . MMMSSSSS|low add 1980 to stored year stored second should be doubled / * write JS date to buf as a DOS date
Writes a Date to a Buffer