summaryrefslogtreecommitdiff
path: root/src/fmt.c
AgeCommit message (Collapse)Author
2007-07-23Update all copyright notices to use the newer form.Jim Meyering
2007-07-10Change "version 2" to "version 3" in all copyright notices.Jim Meyering
2007-03-28Help translators include translation team's web or email address.Jim Meyering
* src/system.h (emit_bug_reporting_address): New function. * src/base64.c: Use it rather than a literal printf. * src/basename.c, src/cat.c, src/chgrp.c, src/chmod.c: * src/chown.c, src/chroot.c, src/cksum.c, src/comm.c, src/cp.c: * src/csplit.c, src/cut.c, src/date.c, src/dd.c, src/df.c: * src/dircolors.c, src/dirname.c, src/du.c, src/echo.c, src/env.c: * src/expand.c, src/expr.c, src/factor.c, src/fmt.c, src/fold.c: * src/head.c, src/hostid.c, src/hostname.c, src/id.c, src/install.c: * src/join.c, src/kill.c, src/link.c, src/ln.c, src/logname.c: * src/ls.c, src/md5sum.c, src/mkdir.c, src/mkfifo.c, src/mknod.c: * src/mv.c, src/nice.c, src/nl.c, src/nohup.c, src/od.c: * src/paste.c, src/pathchk.c, src/pinky.c, src/pr.c, src/printenv.c: * src/printf.c, src/ptx.c, src/pwd.c, src/readlink.c, src/rm.c: * src/rmdir.c, src/seq.c, src/setuidgid.c, src/shred.c, src/shuf.c: * src/sleep.c, src/sort.c, src/split.c, src/stat.c, src/stty.c: * src/su.c, src/sum.c, src/sync.c, src/system.h, src/tac.c: * src/tail.c, src/tee.c, src/test.c, src/touch.c, src/tr.c: * src/true.c, src/tsort.c, src/tty.c, src/uname.c, src/unexpand.c: * src/uniq.c, src/unlink.c, src/uptime.c, src/users.c, src/wc.c: * src/who.c, src/whoami.c, src/yes.c: Likewise.
2007-01-06* src/fmt.c (copy_rest): Correct prefix handling.G.P. Halkes
Don't elide a line with the prefix followed by only white space. (get_line): Move EOF-check to loop-termination condition. * tests/fmt/basic (pfx-1): Adjust test to expect desired result. (pfx-2): Remove test; its premise was contrary to the documentation.
2006-07-09(check_punctuation): Don't assume that isprint etc. returnPaul Eggert
booleans (needed for pre-C99 hosts).
2005-05-14Update FSF postal mail address.Jim Meyering
2005-05-14Update FSF postal mail address.Jim Meyering
2005-03-28(long_options): Use NULL, not `0'.Jim Meyering
2005-03-06Remove `register' keyword.Jim Meyering
2004-10-20(usage): Improve description of --prefix.Paul Eggert
Problem reported by Edward Welbourne.
2004-08-03(COST, MAXWORDS): Add a comment describing some ofPaul Eggert
fmt's arbitrary limits. (TRUE, FALSE): Remove; all uses changed to (true, false). (main): Use bool for booleans. Limit maximum width to MAXCHARS / 2. Use xstrtoul, not xstrtol, to parse width. (copy_rest): Remove unnecessary cast. (get_prefix): Rewrite to avoid cast. (check_punctuation): Use char *, not unsigned char *; C89 requires this. Avoid off-by-one buffer read overrun when line is empty. (flush_paragraph): Don't assume wptr-parabuf is <= INT_MAX. Remove unnecessary casts.
2004-01-21(usage): Use EXIT_SUCCESS, not 0, for clarity.Jim Meyering
(usage): Don't bother normalizing exit status since the arg is already the correct exit status now.
2003-10-18Most .c files (AUTHORS): Revert the WRITTEN_BY/AUTHORS changeJim Meyering
of 2003-09-19. Now, AUTHORS is a comma-separated list of strings. Update the call to parse_long_options so that `AUTHORS, NULL' are the last parameters. * src/true.c (main): Append NULL to version_etc argument list. * src/sys2.h (case_GETOPT_VERSION_CHAR): Likewise.
2003-09-18(WRITTEN_BY): Rename from AUTHORS.Jim Meyering
Begin each WRITTEN_BY string with `Written by ' and end it with `.'. Mark each WRITTEN_BY string as translatable.
2003-07-26(flush_paragraph): Cast field width to `int' to avoid warning on 64-bit systems.Jim Meyering
2003-07-23Don't include headers already included by system.h:Jim Meyering
Don't include closeout.h.
2003-07-11(main): Enclose diagnostic in _(...).Jim Meyering
2003-06-17(main): Call initialize_main.Jim Meyering
2003-05-02(usage): Don't mention obsolescent -WIDTH option.Jim Meyering
Instead explain about `-' and standard input. (main): Give a proper diagnostic for e.g., `fmt -c -72'.
2003-05-02Include "quote.h".Jim Meyering
Use quote() in diagnostics, rather than literal `' marks. (main): Exit nonzero when unable to open an input file.
2003-05-02(main): Diagnose invalid suffix on obsolescent width specifications like `-72x'.Jim Meyering
2003-03-18[struct Word] (paren, period, punct, final): Change theJim Meyering
type of each member from bool <MEMBER>:1 to unsigned int <MEMBER>:1. AIX 5.1's xlc could not compile the former.
2002-12-15Remove all uses of `PARAMS'.Jim Meyering
2002-09-24fmt's -s, -t, -c options didn't work properly for long lines.Jim Meyering
Since get_line may end up calling put_paragraph (for long lines), be sure to set global, `other_indent', before it is used there. (set_other_indent): New function, factored out of... (get_paragraph): ... here. Call it. (get_line): Call set_other_indent before calling flush_paragraph, which calls fmt_paragraph, which in turn calls put_paragraph, which uses other_indent.
2002-08-31Change `exit (0)' to `exit (EXIT_SUCCESS)',Jim Meyering
`exit (1)' to `exit (EXIT_FAILURE)', and `usage (1)' to `usage (EXIT_FAILURE)'.
2002-07-02(usage): Use the PACKAGE_BUGREPORT e-mail address, rather than hard-coding it.Jim Meyering
2001-12-01Reflect renaming to, and new usage of these macros:Jim Meyering
HELP_OPTION_DESCRIPTION and VERSION_OPTION_DESCRIPTION.
2001-12-01(usage): Use new macros, EMIT_HELP_DESCRIPTION and EMIT_VERSION_DESCRIPTIONJim Meyering
instead of hard-coding --help and --version descriptions.
2001-11-23Factor out some common strings to make translation easier.Jim Meyering
Split usage strings so that --help and --version descriptions are alone in their own string. Likewise for the one that says: Mandatory arguments to long options are mandatory for short options too.
2001-11-17Remove `unsigned' attribute from type of global `prefix'.Jim Meyering
(copy_rest): Cast to (unsigned char *) before dereferencing. (get_prefix): Likewise.
2001-11-11(usage): Split --help output into smaller pieces.Jim Meyering
2001-09-12The command `echo a|./fmt -2147483647' would cause fmt to segfault.Jim Meyering
(fmt_paragraph): Test for sentinal directly, rather than doing arithmetic with it's potentially large (INT_MAX) length.
2001-09-12The command `echo foo| fmt -w 100000' would cause fmt to segfault.Jim Meyering
[struct Word]: Declare members length, space, and line_length to be of type `int', not short. (MAXCOST): Define using TYPE_MAXIMUM.
2001-08-31(bool): Remove typedef, now that it's in system.h.Jim Meyering
(TRUE): Define to `true', not 1. (FALSE): Define to `false', not 0.
2001-08-28(main): Diagnose an invalid width option.Jim Meyering
2001-08-28(main): Correct the diagnostic for invalid argument to -w.Jim Meyering
2001-03-12`fmt --prefix=S' would not work properly for any string S containingJim Meyering
a byte with the high bit set. (prefix): Declare to be of type unsigned char, not `char'. (get_prefix): Likewise for local, `p'.
2000-05-20Arrange to call close_stdout upon exit. Don't close stdout explicitly.Jim Meyering
1999-04-04Standardize --help and --version processing.Jim Meyering
1999-04-03Use AUTHORS in place of string in parse_long_options call.Jim Meyering
1999-04-03Insert AUTHORS definition.Jim Meyering
1999-04-03Use PROGRAM_NAME in place of string in parse_long_options call.Jim Meyering
1999-04-03define PROGRAM_NAMEJim Meyering
1999-03-07(main): Use a `%s' format in error call,Jim Meyering
in case the argument string contains a `%'.
1999-03-04Include long-options.hJim Meyering
[long_options]: Remove the "help" and "version" entries. Remove declarations of show_help and show_version. (main): Use parse_long_options, including author name(s). Remove the show_version and show_help blocks.
1999-02-16update copyright datesJim Meyering
1999-01-14Don't prototype usage as static.Jim Meyering
1998-09-19update bug-reporting addressJim Meyering
1998-07-26(check_punctuation): Add cast to placate irix4's cc. Reported by Kaveh Ghazi.Jim Meyering
1998-06-29revert back to using lower case _unlocked wrapper namesJim Meyering