Call cleanup for encoder
Merge pull request #114 from moobyfr/devel

Call cleanup for encoder