Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/sort Since -T is used to select directory for tempor...
details: https://anonhg.NetBSD.org/src/rev/46ff46b42523
branches: trunk
changeset: 503523:46ff46b42523
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Wed Feb 07 20:31:44 2001 +0000
description:
Since -T is used to select directory for temporary files in other sort
implementations, we should avoid using it for something else.
Use (new) flag -w for setting record delimiter, make -T noop.
diffstat:
usr.bin/sort/sort.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diffs (45 lines):
diff -r e153c3cb2ab6 -r 46ff46b42523 usr.bin/sort/sort.c
--- a/usr.bin/sort/sort.c Wed Feb 07 19:47:44 2001 +0000
+++ b/usr.bin/sort/sort.c Wed Feb 07 20:31:44 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sort.c,v 1.19 2001/02/07 19:47:44 jdolecek Exp $ */
+/* $NetBSD: sort.c,v 1.20 2001/02/07 20:31:44 jdolecek Exp $ */
/*-
* Copyright (c) 1993
@@ -51,7 +51,7 @@
#endif /* not lint */
#ifndef lint
-__RCSID("$NetBSD: sort.c,v 1.19 2001/02/07 19:47:44 jdolecek Exp $");
+__RCSID("$NetBSD: sort.c,v 1.20 2001/02/07 20:31:44 jdolecek Exp $");
__SCCSID("@(#)sort.c 8.1 (Berkeley) 6/6/93");
#endif /* not lint */
@@ -112,7 +112,7 @@
fixit(&argc, argv);
- while ((ch = getopt(argc, argv, "bcdfik:mHno:rsSt:T:ux")) != -1) {
+ while ((ch = getopt(argc, argv, "bcdfik:mHno:rsSt:T:uw:x")) != -1) {
switch (ch) {
case 'b':
fldtab->flags |= BI | BT;
@@ -160,6 +160,9 @@
errx(2, "record/field delimiter clash");
break;
case 'T':
+ /* -T tmpdir, noop (not supported) */
+ break;
+ case 'w':
if (REC_D != '\n')
usage("multiple record delimiters");
if ('\n' == (REC_D = *optarg))
@@ -297,6 +300,6 @@
if (msg != NULL)
(void)fprintf(stderr, "sort: %s\n", msg);
(void)fprintf(stderr, "usage: [-o output] [-cmubdfinrsS] [-t char] ");
- (void)fprintf(stderr, "[-T char] [-k keydef] ... [files]\n");
+ (void)fprintf(stderr, "[-w char] [-k keydef] ... [files]\n");
exit(2);
}
Home |
Main Index |
Thread Index |
Old Index