Replacement for ioutil.ReadAll for when you know the length.