summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1994-02-14 21:19:12 +0000
committerJim Meyering <jim@meyering.net>1994-02-14 21:19:12 +0000
commitc6f59f7abe4e89f690021c2ba29dfef8a3cc7a9c (patch)
treecdc4c0fbdb88202f20181f3e257b6b2796e3f419
parente4aba2047ab257bddf475af70f04d15041dd6d70 (diff)
downloadcoreutils-c6f59f7abe4e89f690021c2ba29dfef8a3cc7a9c.tar.xz
.
-rw-r--r--old/sh-utils/ChangeLog36
-rw-r--r--old/sh-utils/NEWS6
-rw-r--r--src/basename.c6
-rw-r--r--src/dirname.c6
-rw-r--r--src/stty.c6
5 files changed, 57 insertions, 3 deletions
diff --git a/old/sh-utils/ChangeLog b/old/sh-utils/ChangeLog
index f82556042..1df78dd8a 100644
--- a/old/sh-utils/ChangeLog
+++ b/old/sh-utils/ChangeLog
@@ -1,3 +1,39 @@
+Sun Feb 13 13:34:25 1994 Jim Meyering (meyering@comco.com)
+
+ * basename.1, dirname.1, stty.1: Reflect usage changes.
+ * basename.c, dirname.c, stty.c (usage): Ditto.
+
+ * long-options.h (parse_long_options): Invoke usage function
+ argument with explicit dereference as per GNU coding standards.
+
+ * basename.c dirname.c: Use parse_long_options instead of the
+ conventional getopt_long paradigm. Before, the commands
+ `basename file-dist -dist' and `basename -- file.c .c' produced
+ incorrect results. Now, even `basename -file-dist -dist' works
+ and the command `basename -- file.c .c' fails for the right
+ reason: the `--' is not a special (to getopt) token for these
+ commands. It is interpreted as the filename, so there are too
+ many arguments to basename. Rick Sladkey <jrs@world.std.com>
+ reported the problem with basename.
+
+ * stty.c (set_window_size): When stty fails to get the window size
+ (as happens on telnet sessions to Solaris systems), initialize all
+ fields of the winsize struct. Before, it was using the uninitialized
+ pixel fields of the struct in the ioctl to set window size parameters.
+ From Rick Sladkey.
+
+ * stty.c (main): Use parse_long_options to handle --help and --version.
+ (main): In the remaining getopt_long loop, don't jump out of the
+ loop from the `default' branch of the switch statement. Doing that
+ left optind in an inconsistent when there were non-option arguments
+ preceding `reversed' arguments (e.g. stty echo -echoe) and the
+ preceding non-option arguments were ignored. Rick Sladkey reported
+ that stty was ignoring arguments.
+
+ * stty.c (main): Fail with a diagnostic when both -g and -a are given.
+ (main): Fail with a diagnostic when either -g or -a is used with
+ arguments for setting modes.
+
Fri Feb 11 19:39:37 1994 Jim Meyering (meyering@comco.com)
* stty.c (get_win_size): Don't use an ANSI-style function
diff --git a/old/sh-utils/NEWS b/old/sh-utils/NEWS
index 70292f824..90958f32d 100644
--- a/old/sh-utils/NEWS
+++ b/old/sh-utils/NEWS
@@ -1,4 +1,10 @@
User visible changes in release 1.9.3
+* `stty -a -g' gets a diagnostic
+* `stty {-a|-g} any-other-argument' gets a diagnostic
+* stty no longer ignores some of its arguments
+* basename and dirname no longer treat `--' specially
+* `basename -- file.c .c' generates a usage error. Before, it output `file'.
+* `basename file-dist -dist' outputs `file'. Before it output `file-dist'.
* stty defaults `swtch' to undefined for Solaris so `susp' (^Z) will work.
Before, with the default settings ^Z did nothing.
* stty no longer gives an error message when it finds a spurious difference
diff --git a/src/basename.c b/src/basename.c
index 6fc11302e..8f773e9aa 100644
--- a/src/basename.c
+++ b/src/basename.c
@@ -59,7 +59,11 @@ usage (status)
program_name);
else
{
- printf ("Usage: %s [OPTION]... PATH [SUFFIX]\n", program_name);
+ printf ("\
+Usage: %s PATH [SUFFIX]\n\
+ or: %s OPTION\n\
+",
+ program_name, program_name);
printf ("\
\n\
--help display this help and exit\n\
diff --git a/src/dirname.c b/src/dirname.c
index a0345be7a..17beaba20 100644
--- a/src/dirname.c
+++ b/src/dirname.c
@@ -48,7 +48,11 @@ usage (status)
program_name);
else
{
- printf ("Usage: %s [OPTION]... PATH\n", program_name);
+ printf ("\
+Usage: %s PATH\n\
+ or: %s OPTION\n\
+",
+ program_name, program_name);
printf ("\
\n\
--help display this help and exit\n\
diff --git a/src/stty.c b/src/stty.c
index 5b3f7f4be..b094f8bce 100644
--- a/src/stty.c
+++ b/src/stty.c
@@ -452,7 +452,11 @@ usage (status)
program_name);
else
{
- printf ("Usage: %s [OPTION]... [SETTING]...\n", program_name);
+ printf ("\
+Usage: %s [SETTING]...\n\
+ or: %s OPTION\n\
+",
+ program_name, program_name);
printf ("\
\n\
-a, --all print all current settings in human-readable form\n\