remove trailing ^M characters on save