summaryrefslogtreecommitdiffstats
path: root/term-utils
Commit message (Collapse)AuthorAgeFilesLines
* agetty: fix memory leak [clang-analyzer]Sami Kerola2013-07-091-1/+3
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* Fixes "getty: unrecognized option '--loginpause'"kernc2013-07-041-2/+2
| | | | | Usage incorrectly stated --loginpause is a valid option, where instead --login-pause is. Also --no-hostname --> --nohostname.
* agetty: improve wording, grammar and some formatting in man pageBenno Schulenberg2013-06-181-49/+49
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* agetty: fix a kill/erase error in man page and improve clarityBenno Schulenberg2013-06-181-12/+12
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* Merge branch 'master' of https://github.com/eric-s-raymond/util-linuxKarel Zak2013-06-131-26/+44
|\ | | | | | | | | | | | | | | | | | | * 'master' of https://github.com/eric-s-raymond/util-linux: Fix broken list syntax. Restore use of correct alternation syntax using { | }. Re-layout a FILES section in the traditional style. Remove another .ti for .RS/.RE, and remove a .TP that broke list parsing. Replace .IP o with .IP \(bu, using the [nt]roff bullet character. Replace .ti operations with equivalent .RS/.RE pairs.
| * Re-layout a FILES section in the traditional style.Eric S. Raymond2013-06-101-5/+12
| |
| * Remove another .ti for .RS/.RE, and remove a .TP that broke list parsing.Eric S. Raymond2013-06-101-8/+11
| |
| * Replace .IP o with .IP \(bu, using the [nt]roff bullet character.Eric S. Raymond2013-06-101-9/+9
| | | | | | | | | | | | | | This will improve the quality of generated HTML. There is a cost, which is that most terminal emulators will just display the bullet as a (less visible) dot. An alternative to this change would be to use a * character for the bullet.
| * Replace .ti operations with equivalent .RS/.RE pairs.Eric S. Raymond2013-06-101-4/+12
| | | | | | | | | | This change makes automatic lifting to XML-DocBook possible, and should enable generation of better-quality HTML from these pages.
* | agetty: use O_NONBLOCK only for serial lines with CLOCALKarel Zak2013-06-131-5/+7
|/ | | | | | | | | | * regression introduced by ef264c830effc91add6da334204215f61eb8515e * also increase sleep when O_NONBLOCK used (grr.. this is so stupid thing, do we really need O_NONBLOCK for the stupid serial lines?) References: https://bugzilla.redhat.com/show_bug.cgi?id=972457 Signed-off-by: Karel Zak <kzak@redhat.com>
* textual: standardize the spelling of "superuser"Benno Schulenberg2013-06-072-2/+2
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* agetty: update man page and usage()Karel Zak2013-06-032-22/+23
| | | | | | | | - baud_rate is optional - agetty has been rewritten 2 years ago, so don't blame original authors in the man page Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: allow full control on CLOCAL flagKarel Zak2013-05-232-9/+49
| | | | | | | | | | | Now the -L option allows to explicitly enable CLOCAL flag. Unfortunately sometimes it's necessary to clear the flag. This patch add optional argument =<mode> to specify 'auto', 'always' and 'never' to control CLOCAL flag. Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=816342 Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: add --disable-settermKarel Zak2013-04-261-4/+1Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* wall: check writing to a file descriptor was successfulSami Kerola2013-04-261-2/+2
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* agetty: check writing to a file was successfulSami Kerola2013-04-261-1/+10
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* various: fix variable and function declarations [smatch scan]Sami Kerola2013-04-091-5/+5
| | | | | | | | | | | | | | | | | disk-utils/fsck.minix.c:511:9: warning: mixing declarations and code fdisks/sfdisk.c:982:5: warning: mixing declarations and code fdisks/sfdisk.c:1254:5: warning: mixing declarations and code fdisks/sfdisk.c:1564:5: warning: mixing declarations and code lib/mbsalign.c:279:7: warning: mixing declarations and code libblkid/src/devname.c:378:17: warning: mixing declarations and code libfdisk/src/alignment.c:219:9: warning: mixing declarations and code term-utils/wall.c:111:9: warning: mixing declarations and code text-utils/col.c:418:19: warning: non-ANSI function declaration of function 'flush_blanks' text-utils/col.c:553:12: warning: non-ANSI function declaration of function 'alloc_line' text-utils/rev.c:105:9: warning: mixing declarations and code text-utils/tailf.c:245:9: warning: mixing declarations and code Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* setterm: fix various color option argument listsSami Kerola2013-04-051-37/+37
| | | | | | | | The lists did not have correct colors in usage(). Because the usage() had to be fixed, it is best to make the output easy for translators to work with. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* agetty: the command does not have -h and -V optionsSami Kerola2013-04-051-3/+2Star
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* docs: remove repeated wordsKarel Zak2013-04-051-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: add --chroot to usage() and man pageKarel Zak2013-04-052-0/+4
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: add -E, --remote to usage()Karel Zak2013-04-051-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: fix memory leak [coverity scan]Karel Zak2013-03-271-1/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lib/xalloc: fix mamory leak in xgethostname() [coverity scan]Karel Zak2013-03-271-4/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: make \{4,6} issue file code more robust [coverity scan]Karel Zak2013-03-271-3/+6
| | | | | | ... and more readable for static analyzers Signed-off-by: Karel Zak <kzak@redhat.com>
* script: use __noreturn__ for really last function [clang -Winvalid-noreturn]Karel Zak2013-03-201-4/+4
| | | | | | Use 'noreturn' for done() only. Signed-off-by: Karel Zak <kzak@redhat.com>
* remove duplicate includesKarel Zak2013-03-201-1/+0Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: make the section AVAILABILITY always come last in man pagesBenno Schulenberg2013-03-201-3/+1Star
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* wall: use xgethostname()Sami Kerola2013-03-041-4/+3Star
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* add missing rpmatch.h everywhere it needs to beWilliam Pitcock2013-02-201-0/+1
| | | | | Signed-off-by: William Pitcock <nenolod@dereferenced.org> Signed-off-by: Karel Zak <kzak@redhat.com>
* a pointer should not be compared to zero [coccinelle]Sami Kerola2013-02-061-2/+2
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* textual: spell and encode the name of Arkadiusz Miƛkiewicz correctlyBenno Schulenberg2013-02-066-6/+6
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* agetty: properly pluralize the reporting of the number of usersBenno Schulenberg2013-01-301-2/+3
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* agetty: make usage() translator friendlySami Kerola2013-01-251-35/+35
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* textual: gettextize several overlooked messagesBenno Schulenberg2013-01-251-13/+13
| | | | | | Also improve the clarity of some of them. Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* textual: tag two bug messages as "internal error"Benno Schulenberg2013-01-251-1/+1
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* script: search shell from path, when necessarySami Kerola2013-01-091-5/+11
| | | | | Addresses: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=518532 Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* include/ttyutils: add default chardataWerner Fink2013-01-081-25/+2Star
| | | | | | | | | | | | this one moves the init_chardata to include/ttyutils.h as well as to lib/include/ttyutils.c. Also the macros CTL/CTRL are fixed in agetty.c and sulogin.c to use the XOR variant CTL. [kzak@redhat.com: use macro rather than global variable for default chardata] Signed-off-by: Werner Fink <werner@suse.de> Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: replace perms 660 to 620Karel Zak2013-01-021-1/+1
| | | | | | ... the default is root:tty 620 Signed-off-by: Karel Zak <kzak@redhat.com>
* sulogin: remove consoles.c from libcommonKarel Zak2012-12-231-14/+3Star
| | | | | | | | - move struct chardata to include/ttyutils.h - move console.{h,c} to login-utils/sulogin-* (it's sulogin specific) - fix sulogin and agetty includes Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: fix compiler warningKarel Zak2012-12-201-1/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: remove @ and # as default kill and erase charsKarel Zak2012-11-222-8/+8
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: add --{erase,kill}-chars optionsKarel Zak2012-11-222-5/+39
| | | | | | | | | | | | | | We need way to disable the default kill and erase agetty chars to make the getty usable for Active Directory users with '@' in username. It seems that the most extendible solution is to add options that allow to complete control additional erase/kill chars. If you specify empty strings then the chars are disabled at all. Note that this patch is backwardly compatible. Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=870854 Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: make --autologin useful with --skip-login (prompt)Karel Zak2012-11-191-4/+8
| | | | | | | | | | | | | | | | | | The --autologin prints hostname login: username (automatic login) message. This commit allows to suppress the message at all if --skip-login (aka skip prompt) is specified. It means that agetty --skip-login --noissue --autologin foouser does completely silent autologin. Addresses: https://github.com/karelzak/util-linux/issues/21 Signed-off-by: Karel Zak <kzak@redhat.com>
* script: do not try to close stderr twiceSami Kerola2012-11-081-3/+5
| | | | | | | | | | | | | | | The commit cdd2a8c360c70d16804ace7cc923a6c6bb7c9ca9 broke script(1) return value. $ script -e -c "echo"; echo $? 1 The reason, as Daniel it reported, was that the script will close stderr twice, once as timing file and atexit() in function close_stdout(). This commit fixes the problem. Reported-by: Daniel Narvaez <dwnarvaez@gmail.com> Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* agetty: fix autodetection for TERMMichal Schmidt2012-11-021-1/+0Star
| | | | | open_tty() autodetects whether to set TERM to "linux" or "vt102", but it can apply the result only if op->term is still NULL.
* agetty: replace gethostbyname() with getaddrinfo()Sami Kerola2012-10-222-7/+19
| | | | | | | | The gethostbyname() is legacy function which may be withdrawn in a future. Reference: http://pubs.opengroup.org/onlinepubs/009695399/functions/gethostbyname.html Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* write: stop using MAXHOSTNAMELENKarel Zak2012-10-191-3/+7
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* agetty: stop using MAXHOSTNAMELENKarel Zak2012-10-191-23/+55
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setterm: make error message more informativePetr Uzel2012-09-211-3/+7
| | | | | | | | | | | | | | | | | | | | | If `setterm -dump` fails because of lack of permission to read /dev/vcsa, it should not report that it couldn't read /dev/vcsa0. This could be misleading if there is only /dev/vcsa, but not /dev/vcsa0. Before: $ ./setterm -dump setterm: Couldn't read /dev/vcsa0 After: $ ./setterm -dump setterm: Couldn't read neither /dev/vcsa0 nor /dev/vcsa (Note: /dev/vcsa0 does not exist and the user does not have read permission on /dev/vcsa in this case). Addresses: https://bugzilla.novell.com/show_bug.cgi?id=780615 Reported-by: Christopher Yeleighton <giecrilj@stegny.2a.pl> Signed-off-by: Petr Uzel <petr.uzel@suse.cz>