Bug#849113: /lib/lsb/init-functions: When echoing status messages, use \r\n instead of \n in case the terminal is in ~OPOST mode
Ben Longbons <[email protected]> Thu, 22 Dec 2016 10:04:25 -0800
| Newsgroups | gmane.linux.debian.devel.lsb |
|---|---|
| Message-ID | <148242986569.5177.16196107584584082313.reportbug__39768.8729492531$1482430162$gmane$org@localhost> |
Package: lsb-base Version: 9.20161125 Severity: wishlist File: /lib/lsb/init-functions Dear Maintainer, When a terminal is in raw mode (in particular, when OPOST is not set in termios.c_oflag, which disables the effect of ONLCR), emitting a \n will only move the cursor down one line, rather than implicitly adding a \r to move to the start of the line. In particular, this often happens when restarting the display manager. To fix, simply ensure that every \n is preceded by a \r. As long as this is only done when output is a terminal, it won't mess up any log files. -Ben -- System Information: Debian Release: stretch/sid APT prefers unstable-debug APT policy: (500, 'unstable-debug'), (500, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386, x32, arm64 Kernel: Linux 4.8.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) -- no debconf information