fix transfer length