jmallett
4586b0f323
Possibly expand the variable name's embedded variables before using it, as
...
seen (somewhat) in NetBSD. This catches a few extra recursion cases that
could be hidden by expanding a NIL variable causing an existing variable to
be returned (which caused infinite looping and climbing memory usage in at
least one case).
Obtained from: NetBSD (in principle)
2002-06-19 17:23:08 +00:00
tjr
aff5678b6e
Fix duplicate % in %b format introduced in rev 1.22.
2002-06-19 09:42:20 +00:00
tjr
80af7bc382
Let printf(1) tell the difference between zero width/precision and
...
unspecified width/precision.
PR: 39116
Submitted by: Egil Brendsdal <egilb@ife.no>
MFC after: 1 week
2002-06-19 09:24:30 +00:00
tjr
2b21f1a948
Allow format strings containing "%%" to be reused.
...
PR: 39116
Submitted by: Egil Brendsdal <egilb@ife.no>
MFC after: 1 week
2002-06-19 08:18:37 +00:00
tjr
95dac58041
Allow `%' to be written out with an octal escape (\45 or \045).
...
PR: 39116
Submitted by: Egil Brendsdal <egilb@ife.no>
MFC after: 1 week
2002-06-19 08:16:14 +00:00
tjr
e03fb12529
Indicate that env(1) allows you to supply arguments to the utility it
...
executes in the usage() message and manual page. Use "utility" instead of
"command" in both places to emphasise that shell builtins etc. will not work,
and to be consistent with the terminology used by POSIX.
PR: 39210
Submitted by: Danny J. Zerkel <dzerkel@columbus.rr.com>
MFC after: 1 week
2002-06-19 07:09:44 +00:00
tjr
eb084e4397
Don't convert a single space before a tab stop into a tab when the
...
-i option is used.
2002-06-19 01:45:03 +00:00
jmallett
1d6e66be9f
make(I) appeared in PWB UNIX.
2002-06-17 13:43:15 +00:00
tjr
07e6e2c6f3
Add Standards section.
2002-06-17 13:37:31 +00:00
tjr
a763475fb1
Sort sections, use Dl for the example so it stands out more.
2002-06-17 13:36:25 +00:00
tjr
430283afe9
Only advance the column position for printable characters, update manual
...
page to emphasise that we count column positions, not characters.
2002-06-17 12:11:05 +00:00
sobomax
9bb33f87d3
Kill superfluous blank line.
2002-06-17 08:21:53 +00:00
grog
47e1ed8bb9
Remove 17 June as German national holiday.
2002-06-16 22:59:21 +00:00
tjr
0588706f27
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
tjr
73014ec07e
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
jmallett
04a334b0ce
Remove local prototype for main().
2002-06-15 11:28:09 +00:00
jmallett
fe733a8c21
Protoize. Remove un-needed cast to char in switch of getopt(3)'s return value.
...
FBSDID.
2002-06-15 11:26:25 +00:00
jmallett
c492727786
Remove <sys/types> where we use <sys/param> already.
...
protoize.
2002-06-15 11:03:28 +00:00
tjr
b09484b4f3
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
tjr
7853af48f5
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
mikeh
379207e179
Update for lukemftp-1.6-beta2.
2002-06-15 09:42:17 +00:00
tjr
97dbe1e674
Sort sections.
2002-06-15 08:41:12 +00:00
tjr
7abf4fbe29
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
tjr
361d0dd8a7
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
tjr
1fa61e7038
Move the #include and #define's to the top of the file.
2002-06-14 15:56:52 +00:00
tjr
38575dbfdf
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
tjr
6e2af6c134
Use the Cm macro for the clear, init, reset and longname operands.
2002-06-14 15:16:03 +00:00
tjr
99e93d002e
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
tjr
f8e6c7f292
Sort sections. Avoid using "The -? option" at the start of option descriptions.
2002-06-14 10:11:41 +00:00
tjr
5a8b5dcfa4
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
tjr
29924b60f3
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
tjr
0c8a9db6f9
Implement support for equivalence classes ([=e=]) when the mapping is
...
one-to-one (SUSv3)
2002-06-14 07:37:08 +00:00
tjr
b7f83f53f9
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
sobomax
0c8f30b575
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
grog
e930b35ecd
beforeinstall target:
...
- Remove superfluous ;
- create destination directories if they don't exist.
2002-06-13 21:21:59 +00:00
grog
fb4608bacb
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
tjr
16f907d030
Correct the Standards section: wc is a utility, not a function.
2002-06-13 13:18:57 +00:00
tjr
3d069b8f73
Bump document date for previous commit.
2002-06-13 13:17:00 +00:00
tjr
1e238aa8c3
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
jmallett
63759e6467
Avoid classy use of a variable one time with a constant value.
2002-06-13 08:57:53 +00:00
jmallett
0ca350a1fa
Use %p to print a pointer, not %lx and a cast to (unsigned long). Yuck.
2002-06-13 08:55:29 +00:00
jmallett
a41b038bb5
Don't do stupid things to avoid unused parameters, mark them __unused.
2002-06-13 08:54:16 +00:00
des
5a55cbe1eb
Reorder LDADD to fix static linking.
2002-06-12 12:46:50 +00:00
jmallett
c3b688425d
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
jmallett
7114af77d0
The error functions take constant pointers to strings for their format.
2002-06-12 04:11:01 +00:00
robert
f85d0f0060
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
tjr
fca980a9e4
paste(1) appeared at least as early as 32v.
2002-06-11 08:13:03 +00:00
tjr
3409f7ad48
cut(1) appeared at least as early as System III.
2002-06-11 08:11:12 +00:00
jmallett
241a475e6f
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
tjr
8ebea63ae6
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