On Wednesday 2011-12-21 15:08, Zbigniew Jędrzejewski-Szmek wrote: > On 12/21/2011 02:23 PM, Jan Engelhardt wrote: >> +unsigned int console_width(void) >> +{ >> ... >> +} >> + > > Hi, > there already is columns() in src/util.c :)
It gets the #columns from stdout rather than /dev/console to which the status string is to be written, and keeps the value around forever without updating even if stdout changes its terminal size. Speaking of which, SIGWINCH is abused in that regard... _______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel