added saving into buffer & io for saved message