summaryrefslogtreecommitdiffstats
path: root/usr.bin/du/du.c
diff options
context:
space:
mode:
authorkientzle <kientzle@FreeBSD.org>2004-05-02 17:54:57 +0000
committerkientzle <kientzle@FreeBSD.org>2004-05-02 17:54:57 +0000
commit83908c5c8bf575f03a8724ada695c3ad2c0b9b0c (patch)
treedd9da25642339ebaa676999a701b38e99e50cf0a /usr.bin/du/du.c
parent578eca06dcca0633eddb397f27606be5e9d01db1 (diff)
downloadFreeBSD-src-83908c5c8bf575f03a8724ada695c3ad2c0b9b0c.zip
FreeBSD-src-83908c5c8bf575f03a8724ada695c3ad2c0b9b0c.tar.gz
More style fixes, per bde.
Diffstat (limited to 'usr.bin/du/du.c')
-rw-r--r--usr.bin/du/du.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/usr.bin/du/du.c b/usr.bin/du/du.c
index 3faa2a7..24f2179 100644
--- a/usr.bin/du/du.c
+++ b/usr.bin/du/du.c
@@ -326,8 +326,7 @@ linkchk(FTSENT *p)
struct links_entry *le, **new_buckets;
struct stat *st;
size_t i, new_size;
- int count;
- int hash;
+ int count, hash;
st = p->fts_statp;
@@ -336,14 +335,13 @@ linkchk(FTSENT *p)
number_buckets = links_hash_initial_size;
buckets = malloc(number_buckets * sizeof(buckets[0]));
if (buckets == NULL)
- errx(1, "No memory for hardlink detection.");
+ errx(1, "No memory for hardlink detection");
for (i = 0; i < number_buckets; i++)
buckets[i] = NULL;
}
/* If the hash table is getting too full, enlarge it. */
if (number_entries > number_buckets * 10 && !stop_allocating) {
-
new_size = number_buckets * 2;
new_buckets = malloc(new_size * sizeof(struct links_entry *));
count = 0;
@@ -360,7 +358,7 @@ linkchk(FTSENT *p)
if (new_buckets == NULL) {
stop_allocating = 1;
- warnx("No more memory for tracking hard links.");
+ warnx("No more memory for tracking hard links");
} else {
memset(new_buckets, 0,
new_size * sizeof(struct links_entry *));
@@ -428,7 +426,7 @@ linkchk(FTSENT *p)
le = malloc(sizeof(struct links_entry));
if (le == NULL) {
stop_allocating = 1;
- warnx("No more memory for tracking hard links.");
+ warnx("No more memory for tracking hard links");
return (0);
}
le->dev = st->st_dev;
OpenPOWER on IntegriCloud