faster parsing of header