diff options
author | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-07-13 17:47:47 +0000 |
---|---|---|
committer | Nicholas Marriott <nicm@cvs.openbsd.org> | 2009-07-13 17:47:47 +0000 |
commit | c2c663e118deaaeb506c6b6fdd8d7c672ce0c680 (patch) | |
tree | d096eba061c552bc79881ce87d35a568697dc746 /usr.bin/last | |
parent | 05c6d0668eda3213f427d840f5f588636d06a4d2 (diff) |
Tidy up and improve target (-t) argument parsing:
- move the code back into cmd.c and merge with the existing functions where
possible;
- accept "-tttyp0" as well as "-t/dev/ttyp0" for clients;
- when looking up session names, try an exact match first, and if that fails
look for it as an fnmatch pattern and then as the start of a name - if more
that one session matches an error is given; so if there is one session called
"mysession", -tmysession, -tmysess, -tmysess* are equivalent but if there
is also "mysession2", the last two are errors;
- similarly for windows, if the argument is not a valid index or exact window
name match, try it against the window names as an fnmatch pattern and a
prefix.
Diffstat (limited to 'usr.bin/last')
0 files changed, 0 insertions, 0 deletions