Reads the next expected.length characters from the input. Fails if they are not exactly expected.
expected.length