From 68d1d44b4798a26eb2bd6a50274f790400b8e63e Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sat, 9 Oct 1993 19:43:03 +0000 Subject: GNU file utilities --- lib/argmatch.c | 4 ++-- lib/backupfile.c | 8 ++++---- lib/fsusage.c | 6 +++--- lib/idcache.c | 2 +- lib/mountlist.c | 6 +++--- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/lib/argmatch.c b/lib/argmatch.c index bf1581aa34..1994c935aa 100644 --- a/lib/argmatch.c +++ b/lib/argmatch.c @@ -49,9 +49,9 @@ argmatch (arg, optlist) int arglen; /* Length of ARG. */ int matchind = -1; /* Index of first nonexact match. */ int ambiguous = 0; /* If nonzero, multiple nonexact match(es). */ - + arglen = strlen (arg); - + /* Test all elements for either exact match or abbreviated matches. */ for (i = 0; optlist[i]; i++) { diff --git a/lib/backupfile.c b/lib/backupfile.c index ddf3fa7894..cb94429038 100644 --- a/lib/backupfile.c +++ b/lib/backupfile.c @@ -156,11 +156,11 @@ max_backup_version (file, dir) int highest_version; int this_version; int file_name_length; - + dirp = opendir (dir); if (!dirp) return 0; - + highest_version = 0; file_name_length = strlen (file); @@ -168,7 +168,7 @@ max_backup_version (file, dir) { if (!REAL_DIR_ENTRY (dp) || NLENGTH (dp) <= file_name_length) continue; - + this_version = version_number (file, dp->d_name, file_name_length); if (this_version > highest_version) highest_version = this_version; @@ -207,7 +207,7 @@ version_number (base, backup, base_length) { int version; char *p; - + version = 0; if (!strncmp (base, backup, base_length) && ISDIGIT (backup[base_length])) { diff --git a/lib/fsusage.c b/lib/fsusage.c index 28c54ac179..7f7a4a7cd8 100644 --- a/lib/fsusage.c +++ b/lib/fsusage.c @@ -31,7 +31,7 @@ int statfs (); -#if defined (STATFS_OSF1) /* DEC Alpha running OSF/1 */ +#if defined (STAT_STATFS3_OSF1) /* DEC Alpha running OSF/1 */ # include #endif @@ -95,13 +95,13 @@ get_fs_usage (path, disk, fsp) char *path, *disk; struct fs_usage *fsp; { -#if defined (STATFS_OSF1) +#if defined (STAT_STATFS3_OSF1) struct statfs fsd; if (statfs (path, &fsd, sizeof (struct statfs)) != 0) return (-1); #define convert_blocks(b) adjust_blocks ((b),fsd.f_fsize, 512) -#endif /* STATFS_OSF1 */ +#endif /* STAT_STATFS3_OSF1 */ #ifdef STAT_STATFS2_FS_DATA /* Ultrix. */ struct fs_data fsd; diff --git a/lib/idcache.c b/lib/idcache.c index 5242366ac6..ff52e0e75c 100644 --- a/lib/idcache.c +++ b/lib/idcache.c @@ -210,7 +210,7 @@ getgidbyname (group) group_alist = tail; return &tail->id.g; } - + tail->next = nogroup_alist; nogroup_alist = tail; return 0; diff --git a/lib/mountlist.c b/lib/mountlist.c index 55e79b12a7..d68cf8dcee 100644 --- a/lib/mountlist.c +++ b/lib/mountlist.c @@ -109,7 +109,7 @@ xatoi (cp) char *cp; { int val; - + val = 0; while (*cp) { @@ -386,7 +386,7 @@ read_filesystem_list (need_fs_type, all_fs) me->me_type = xstrdup ((*ent)->mt_fstype); me->me_dev = -1; /* Magic; means not known yet. */ me->me_next = NULL; - + /* Add to the linked list. */ mtail->me_next = me; mtail = me; @@ -459,7 +459,7 @@ read_filesystem_list (need_fs_type, all_fs) } else { - me->me_devname = xstrdup (thisent + + me->me_devname = xstrdup (thisent + vmp->vmt_data[VMT_OBJECT].vmt_off); } me->me_mountdir = xstrdup (thisent + vmp->vmt_data[VMT_STUB].vmt_off); -- cgit v1.2.1