Commit Graph

15 Commits

Author SHA1 Message Date
christos 7afd9e136a PR/33709: Kevin Massey: Avoid stack smashing in args copy 2006-06-13 03:22:00 +00:00
garbled d8817d5ac1 Apply modified fix for PR bin/23763
jot(1)'s output now matches the examples given in the manpage.
2006-01-07 07:09:01 +00:00
perry 10e955c2f8 de-__P, ANSIfy prototypes 2006-01-04 01:44:06 +00:00
peter 2c12af6a77 Sort options, standardize usage message.
ok wiz@
2004-11-22 17:34:24 +00:00
jmmv b635f565e7 Homogenize usage messages: make the 'usage' word all lowercase, as this seems
to be the most common practice in our tree.
2004-01-05 23:23:32 +00:00
agc 89aaa1bb64 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22365, verified by myself.
2003-08-07 11:13:06 +00:00
atatat 3db0e47b56 Make the randomness a tad more random. It's still not terribly
random, but it's considerably less lame now.

before% echo `jot -r 5` ; echo `jot -r 5`
66 5 78 82 66
66 5 78 82 66

after% echo `jot -r 5` ; echo `jot -r 5`
15 94 47 32 25
78 52 73 52 47
2002-09-27 20:54:51 +00:00
simonb 618d628845 Reverse the if and else clauses for the chardata test if there is
no format string specified.

Fixes PR bin/12424 from Jim Bernard.
2001-03-17 11:43:06 +00:00
jdolecek 507cbfd5d0 Use patch provided Paul Janzen <pjanzen@OpenBSD.org> to fix
bin/12316 more completely.
Highlights:
* we only allow explicitly specified set of (numberic) formats
* %% is correctly skipped, extra %foo formats are detected
* '*' in format specification is not allowed

The code in getformat() is slighly different to the OpenBSD version
of fix - the list of allowed printf(3) flags is explicit and the
condition checking 'chardata' is written slighly differently.

Also pull-in some cosmetic changes from OpenBSD - s/isdefault()/is_default()/,
error() -> errx(), usage().
2001-03-14 07:50:06 +00:00
jdolecek 13cb1a6488 Don't coredump if format given via -w doesn't contain alphanumeric
character; in such case, warn user the format is invalid.

This addresses bin/12316 by Perry E. Metzger.
2001-03-02 21:17:31 +00:00
christos 844b3dce90 char -> unsigned char 1998-12-19 17:06:20 +00:00
lukem ac4e9aa74a WARNSify, fix .Nm usage, deprecate register, use <err.h> 1997-10-19 03:32:11 +00:00
pk 22e62219f7 Allocate proper storage.
Avoid interpretation of boring words as printf(3) style format strings.
1994-12-02 20:29:43 +00:00
jtc 6e0c4ded79 Changed to conform to NetBSD's new RCS Id convention. 1994-11-14 20:27:21 +00:00
jtc 9636069c3e imported from 4.4lite 1994-11-14 20:11:58 +00:00