Tim J. Robbins
254fac850d
Correct the handling of (for example) the N command by only zeroing the
...
input space in mf_fgets() if we reach the end of all input files.
2002-06-16 08:44:39 +00:00
Tim J. Robbins
abd0c85dcd
When counting words, check the correct character variable to see whether it's
...
a space or not.
Noticed by: bde
2002-06-16 06:04:43 +00:00
Juli Mallett
9ed3737fca
Remove local prototype for main().
2002-06-15 11:28:09 +00:00
Juli Mallett
cf0def9349
Protoize. Remove un-needed cast to char in switch of getopt(3)'s return value.
...
FBSDID.
2002-06-15 11:26:25 +00:00
Juli Mallett
2c69ee9b45
Remove <sys/types> where we use <sys/param> already.
...
protoize.
2002-06-15 11:03:28 +00:00
Tim J. Robbins
e4bbbf073b
Remove obsolescent -tabstop option from Synopsis (it was already removed
...
from the usage() message). Document what the -t option does in a more
standard place. Add a standard Diagnostics section.
2002-06-15 10:52:20 +00:00
Tim J. Robbins
ec85e6a06c
Allow <blank>s to be used to separate tab stop positions with the -t
...
argument, not just ASCII space characters and commas. Don't count
non-printing characters when determining column position.
2002-06-15 10:16:39 +00:00
Mike Heffner
3ba0209ecf
Update for lukemftp-1.6-beta2.
2002-06-15 09:42:17 +00:00
Tim J. Robbins
fc3b416102
Sort sections.
2002-06-15 08:41:12 +00:00
Tim J. Robbins
a1a27143bd
fstat() returns information about the target of any symbolic link that
...
was opened, not the link itself. Remove dead code.
2002-06-15 08:31:19 +00:00
Tim J. Robbins
232a0ff51d
Improve parsing of character and equivalence classes:
...
[:*] and [=*] are parsed as `infinitely many repetitions of :' (or *)
instead of literal characters (SUSv3)
2002-06-15 07:38:27 +00:00
Tim J. Robbins
dc20d4b9d4
Move the #include and #define's to the top of the file.
2002-06-14 15:56:52 +00:00
Tim J. Robbins
4efc23dabf
Bump the size of the equivalence set to NCHARS; this file was left out
...
of a previous commit implementing equivalence classes.
2002-06-14 15:53:38 +00:00
Tim J. Robbins
2533f1e42a
Use the Cm macro for the clear, init, reset and longname operands.
2002-06-14 15:16:03 +00:00
Tim J. Robbins
e6da78f41d
Adjust the exit status to conform to SUSv3 and document the fact it takes
...
multiple `argument' operands.
2002-06-14 15:08:05 +00:00
Tim J. Robbins
6eb0710e98
Sort sections. Avoid using "The -? option" at the start of option descriptions.
2002-06-14 10:11:41 +00:00
Tim J. Robbins
e73c3d279c
Don't treat the trailing ']' of an equivalence class expression as a
...
character in the set. tr -d '[=a=]' was deleting ]'s as well as a's.
Noticed by the textutils test suite.
2002-06-14 09:53:11 +00:00
Tim J. Robbins
dfac4f3695
Add the P1003.1-2001 -C option which complements the set of characters
...
(not byte values) specified by the first string argument.
2002-06-14 08:58:30 +00:00
Tim J. Robbins
85f6c317ea
Implement support for equivalence classes ([=e=]) when the mapping is
...
one-to-one (SUSv3)
2002-06-14 07:37:08 +00:00
Tim J. Robbins
6689fb2bbc
Exit with non-zero status if an input file can not be opened. This was
...
broken by rev. 1.22.
2002-06-14 02:20:05 +00:00
Maxim Sobolev
8701af62ee
Fix one serious bug and one potential problem with in-place editing code:
...
- original version of code worked incorrectly when more than one
input files were specified - it was moving the last line from the 1st file
to be the first line of the 2nd, last line of the 2nd to be the first
line of the 3rd and so on;
- use mmap()->write() to create temporary file instead of
malloc()->read()->write(), which was not only slower, but also did not
bother to free allocated memory once backup file was created, potentially
leading to memory exhausting when regex is applied to a big file or a large
number of small ones.
2002-06-14 01:28:52 +00:00
Greg Lehey
9b838be73b
beforeinstall target:
...
- Remove superfluous ;
- create destination directories if they don't exist.
2002-06-13 21:21:59 +00:00
Greg Lehey
b20a21a6c1
Add two new options:
...
-W is like -A (number of days in the future to consider, but also
specifies that we don't want special treatment at weekends.
-F changes our notion of "Friday" (the day before the weekend).
Arguably, calendar(1) is broken to have special treatment of weekends
by default, but this method maintains POLA.
2002-06-13 21:20:56 +00:00
Tim J. Robbins
e785a241f2
Correct the Standards section: wc is a utility, not a function.
2002-06-13 13:18:57 +00:00
Tim J. Robbins
561a45cac3
Bump document date for previous commit.
2002-06-13 13:17:00 +00:00
Tim J. Robbins
ebb42aee31
Add the -m option, which counts characters (as opposed to -c, which
...
counts bytes). In locales that don't have multibyte characters, -m
is effectively an alias for -c.
This brings wc(1) up to P1003.1-2001 conformance.
2002-06-13 12:48:50 +00:00
Juli Mallett
a446b510a4
Avoid classy use of a variable one time with a constant value.
2002-06-13 08:57:53 +00:00
Juli Mallett
536ceed1fc
Use %p to print a pointer, not %lx and a cast to (unsigned long). Yuck.
2002-06-13 08:55:29 +00:00
Juli Mallett
bea86ac44d
Don't do stupid things to avoid unused parameters, mark them __unused.
2002-06-13 08:54:16 +00:00
Dag-Erling Smørgrav
6414f0b970
Reorder LDADD to fix static linking.
2002-06-12 12:46:50 +00:00
Juli Mallett
d2c462cec8
String lengths and sizeof()s are size_t not int. Mark an unused parameter
...
of ReadMakefile as __unused, it's there because this function is used by
the abstracted list interface which normally deals with item handlers which
take two arguments. Add a missing static prototype.
2002-06-12 04:18:31 +00:00
Juli Mallett
22c26d85e3
The error functions take constant pointers to strings for their format.
2002-06-12 04:11:01 +00:00
Robert Drehmel
ddd16e87d0
Use the constants from <limits.h> for the sizes of integral C types
...
rather than defining them ourselves.
2002-06-11 11:27:20 +00:00
Tim J. Robbins
30f8b6c182
paste(1) appeared at least as early as 32v.
2002-06-11 08:13:03 +00:00
Tim J. Robbins
84fb5a42d2
cut(1) appeared at least as early as System III.
2002-06-11 08:11:12 +00:00
Juli Mallett
6fc8ba94c6
Note that this appeared at least as early as PWB UNIX.
...
Use the literal string 'PWB UNIX', as we still have no .At macro for it.
2002-06-10 22:59:59 +00:00
Tim J. Robbins
3ebf2779b3
Remove -j from synopsis. The form given in the synopsis was incorrect,
...
and it should not have been there at all since it is a deprecated option.
2002-06-10 10:39:33 +00:00
Tim J. Robbins
2a84afe106
When stat(2) fails, put the name of the component it failed on in the
...
warning message as well as the path argument.
2002-06-10 10:03:46 +00:00
Juli Mallett
851623f449
Add another example for using paste(1) since tjr seemed to want more examples
...
on IRC. This one is to create a colon seperated list of directories from
find(1), suitable for use in the shell's PATH.
2002-06-10 09:03:49 +00:00
Tim J. Robbins
76d70052fb
Add an EXAMPLES section with three examples. Document the problem with
...
multibyte characters and the -d option in a BUGS section.
2002-06-10 08:50:56 +00:00
Tim J. Robbins
e7cc3a2191
Refer to environ(7) for description of COLUMNS instead of describing it
...
in-line. Document effects of locale environment variables in the same way.
2002-06-10 07:55:13 +00:00
Tim J. Robbins
1fa600e8fe
The 10 occurrence limit for the `s' command documented here has not existed
...
for a very long time (or never did exist).
2002-06-10 07:44:04 +00:00
Tim J. Robbins
2ef53777fd
Newlines are not escaped anymore.
2002-06-10 07:27:32 +00:00
Tim J. Robbins
e307a7a172
Don't write escape newlines with `l' command (SUSv3)
2002-06-10 07:25:35 +00:00
Tim J. Robbins
03fef72fe9
Correctly handle global substitutions where the pattern is only "$", the
...
EOL anchor, when the last input line does not end in a newline character.
Picked up by the GNU sed test suite.
2002-06-10 06:06:20 +00:00
Juli Mallett
a13d4e42c2
Note early appearence of some commands. These actually appeared in PWB, but
...
it seems we don't have a macro for that yet, so list them in the first UNIX
release since then that we have a .At for: v7.
2002-06-10 05:03:20 +00:00
Doug Barton
b075c273da
Per previous discussion, and with Mark's blessing, update the value
...
of this knob to reflect (-)current reality.
2002-06-09 09:28:02 +00:00
Tim J. Robbins
e8d0276426
Use the Tn macro for COBOL, FORTRAN, PL/1, SNOBOL.
2002-06-08 11:40:12 +00:00
Tim J. Robbins
cbffce5928
Support the "--" end-of-options marker.
2002-06-08 11:33:22 +00:00
Tim J. Robbins
21e502a74c
nroff and pr no longer try to disallow messages.
2002-06-08 10:19:07 +00:00