Bugfix: create new output buffer if the current one has different length (appears in some files with fixed blocking strategy)