End-of-line handling