Moved accumulation buffer to local variable.
Handle multiline sequence splits and EOF.