Update byte counts unconditionally.

Rather than updating the byte counts in the error path and after the error
path, do it unconditionally before checking the error.