Tag update. Fixed output buffer bug. Fixes #46