Jim Meyering
df445b0891
Remove old-style xmalloc and xrealloc decls.
1997-10-25 22:03:55 +00:00
Jim Meyering
05bbdbd786
update bug-reporting address
1997-10-07 23:53:36 +00:00
Jim Meyering
03ae2c6b97
Remove old-style savedir dcl.
...
Include savedir.h for prototype.
1997-10-04 01:57:12 +00:00
Jim Meyering
0cc1681a5b
Remove global variable opt_human_readable.
...
(enum Output_units): Rename from output_size.
Rename size_* to Unit_*.
Add Unit_variable to correspond to --human-readable.
(convert_blocks): Remove now-unused definition.
(human_readable): Rename paramater n_bytes to n_blocks.
Adjust conversions to reflect fact that input is now number of
512-byte blocks, not bytes.
(print_size): New function.
(du_files): Use print_size instead of open coding it.
(count_entry): Always count in units of 512-byte blocks to delay.
This lets du accumulate totals corresponding to a terabyte before
overflowing 32-bit long int.
Use print_size instead of open coding it.
1997-05-25 21:23:15 +00:00
Jim Meyering
1b71b3372e
(convert_blocks): Remove now-unnecessary #undef.
...
(du_files): Pass output_size unchanged to convert_blocks. No need
to test output_size for size_bytes, convert_blocks handles that
correctly.
(count_entry): Likewise.
1997-05-25 14:21:41 +00:00
Jim Meyering
1ba34180d7
(main): Implement new --max-depth=N option.
...
Based on the idea and a patch from Torbjorn Lindgren.
(du_files): Likewise.
(count_entry): Likewise.
[AIX]: Remove unused #pragma alloca.
1997-05-25 14:11:50 +00:00
Jim Meyering
cc093a9945
(main): Implement new --max-depth=N option.
...
Based on the idea and a patch from Torbjorn Lindgren.
(du_files): Likewise.
(count_entry): Likewise.
1997-03-27 05:47:56 +00:00
Jim Meyering
b7ffe8cdaf
update copyrights for 1997
1997-02-09 04:52:50 +00:00
Jim Meyering
1d286acd9a
(hash_insert2): Rename local HTAB to HT to avoid shadowing global.
1997-02-02 20:44:10 +00:00
Jim Meyering
a882d55b52
bracket bug address with <> and append a period
1997-02-01 04:24:08 +00:00
Jim Meyering
4f51b86bfb
Compare getopt_long return value against -1, not EOF. Use NULL, not '(int *) 0' as last parameter in getopt_long call.
1997-02-01 03:03:44 +00:00
Jim Meyering
7f798f5f4f
(count_entry): Fix blatant bug (typo?) that made
...
--megabytes report numbers in units of kilobytes.
Reported by Galen Hazelwood.
1997-01-26 05:05:06 +00:00
Jim Meyering
5582e6dad3
change bug-reporting address
1996-11-03 03:16:27 +00:00
Jim Meyering
b8e689dc67
change bug-reporting address
1996-11-02 20:44:15 +00:00
Jim Meyering
4f28f318d8
(main): update --version output to conform to coding standard
1996-10-05 13:14:11 +00:00
Jim Meyering
de05a873ec
(main): update --version output to conform to coding standard
1996-10-04 04:16:01 +00:00
Jim Meyering
c9fff51897
(usage): remove spurious trailing \n in puts.
1996-08-31 04:44:31 +00:00
Jim Meyering
7e294bac78
(usage): Tell where to report bugs.
1996-08-29 05:05:57 +00:00
Jim Meyering
d38f60e27c
(usage): Sort option descriptions in dictionary order.
1996-07-14 12:54:12 +00:00
Jim Meyering
272f8d891e
(usage): The long-named arg is --human-readable, not --human.
1996-04-24 05:05:34 +00:00
Jim Meyering
dc98736719
update Copyright years for 1996
1996-04-24 04:42:21 +00:00
Jim Meyering
5de0b392f2
Update FSF's address.
1996-03-24 18:47:09 +00:00
Jim Meyering
bb6a548712
(main): Declare to be of type int, not void.
1996-03-21 22:45:19 +00:00
Jim Meyering
ca0246a4c1
Don't include version.h.
...
(main): Use PACKAGE_VERSION instead of version_string.
1996-03-16 16:49:28 +00:00
Jim Meyering
10c96c43ac
(main): Initialize for internationalized message support: call setlocale,
...
bindtextdomain, and textdomain.
1996-03-12 03:08:30 +00:00
Jim Meyering
3b69e6514c
Remove comma after last item in enum.
...
(human_readable): Fix off-by-one error that converted
1024*1024 to 1024K rather than 1G. Describe the function.
1996-02-01 04:13:26 +00:00
Jim Meyering
7bfb13dea7
Tweak usage.
1996-01-20 14:27:56 +00:00
Jim Meyering
744d31d57a
(main): New options --human-readable (-h) and --megabytes (-m).
...
(human_readable): New function.
From Larry McVoy (lm@sgi.com ).
1996-01-20 14:26:04 +00:00
Jim Meyering
073c4cb543
Mark all translatable strings using po-mode.el.
1995-11-29 19:24:52 +00:00
Jim Meyering
57ec0f45c9
s/non-zero/nonzero/g
1995-11-27 05:34:31 +00:00
Jim Meyering
f1e1eb58be
Break long lines.
1995-11-15 15:45:28 +00:00
Jim Meyering
c6ca8a1528
Remove bogus __P junk on xstat dcl.
1995-11-10 14:44:37 +00:00
Jim Meyering
b7b00aad08
Protect prototypes with __P.
1995-11-09 23:41:10 +00:00
Jim Meyering
c0d94c89ec
Protoize.
1995-11-09 17:02:23 +00:00
Jim Meyering
b3303ba072
Declare stat, xstat.
1995-10-01 22:40:11 +00:00
Jim Meyering
be22aff966
(save_cwd, restore_cwd, free_cwd): Remove functions.
...
New versions have been broken out into save-cwd.c.
(du_files): Adapt to handle status code returned by new versions
of save_cwd and restore_cwd.
(count_entry): Likewise.
1995-08-05 03:10:27 +00:00
Jim Meyering
ec8d1fce62
(main): Include program name in --version output.
1995-06-22 18:43:14 +00:00
Jim Meyering
ee79446888
(usage): Add one or two lines of descriptive text.
1995-05-22 04:30:18 +00:00
Jim Meyering
99ce9e9832
Use stat (lstat), not safe_stat (safe_lstat).
1995-05-13 12:48:33 +00:00
Jim Meyering
1423198343
add 1995 to Copyright dates
1995-03-10 04:15:06 +00:00
Jim Meyering
6812f61900
(restore_cwd): Test whether fchdir return value is non-zero, not negative.
...
Be consistent!
1995-02-23 21:14:12 +00:00
Jim Meyering
aeebbd038c
(save_cwd) [!HAVE_FCHDIR]: Avoid a core dump via abort() which occurred
...
because cwd->desc was uninitialed.
(restore_cwd) [!HAVE_FCHDIR]: Remove unnecessary redefinition of fchdir.
Both from Bruno Haible.
1995-02-23 21:12:11 +00:00
Jim Meyering
875eafd489
(count_entry): Fix bug in polarity of safe-stat status test.
1995-02-21 05:19:03 +00:00
Jim Meyering
03daea30a6
(save_cwd, restore_cwd): New functions.
...
(main): Use them instead of in-line versions.
(count_entry): Use them here instead of relying on chdir ("..") --
but only when necessary. Before, with --dereference (-L),
traversing a symlink caused failure because chdir ("..") didn't
work as expected. Reported by Bruno Haible.
1995-02-21 05:01:08 +00:00
Jim Meyering
69f39255bc
Rename SAFE_STAT and SAFE_LSTAT to lower case names.
1995-01-27 17:03:21 +00:00
Jim Meyering
59097c0922
Include "error.h" rather than simply declaring `void error ();'.
1994-12-27 13:36:22 +00:00
Jim Meyering
1d6dc36be9
(du_files): Handle very low-probability fchdir failure (when errno != 0
...
&& errno != EINVAL).
1994-12-03 20:38:20 +00:00
Jim Meyering
9f715b2bdb
(du_files): Variable name changes.
1994-12-03 20:29:28 +00:00
Jim Meyering
103e83b65e
(du_files): Work around SunOS restriction that fchdir doesn't work when
...
accounting is enabled -- modelled after djm's find.c mods.
1994-12-03 20:26:33 +00:00
Jim Meyering
2e9d555f8c
.
1994-10-27 13:45:55 +00:00