Cleanup line number processing