From 3e28e72e409550f398d006b7e1fa073bd23e1cfd Mon Sep 17 00:00:00 2001 From: Christof Hanke Date: Mon, 31 Aug 2009 15:39:02 +0200 Subject: [PATCH] Remove unnecessary type ViceFid The type "ViceFid" is just a clone of the type AFSFid and used only in a couple of places. Thus, for simplicity, rename all occurences of ViceFid to AFSFid and remove the typedef itself. Reviewed-on: http://gerrit.openafs.org/383 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman Tested-by: Derrick Brashear Reviewed-by: Derrick Brashear --- src/fsint/afsint.xg | 2 -- src/packaging/Debian/patches/alloc-vnode | 2 +- src/vol/vol-salvage.c | 10 +++++----- src/volser/volprocs.c | 2 +- 4 files changed, 7 insertions(+), 9 deletions(-) diff --git a/src/fsint/afsint.xg b/src/fsint/afsint.xg index 18056fd3df..98fb106fd6 100644 --- a/src/fsint/afsint.xg +++ b/src/fsint/afsint.xg @@ -35,8 +35,6 @@ customized struct AFSAccessList { char *SeqBody; }; -typedef AFSFid ViceFid; - typedef afs_int32 ViceDataType; %#define Invalid 0 diff --git a/src/packaging/Debian/patches/alloc-vnode b/src/packaging/Debian/patches/alloc-vnode index 9c4d535c32..e4e703cc56 100644 --- a/src/packaging/Debian/patches/alloc-vnode +++ b/src/packaging/Debian/patches/alloc-vnode @@ -9,7 +9,7 @@ Debian Bug#448380 +++ openafs/src/volser/volprocs.c @@ -210,14 +210,14 @@ struct acl_accessList *ACL; - ViceFid did; + AFSFid did; Inode inodeNumber, nearInode; - char buf[SIZEOF_LARGEDISKVNODE]; - struct VnodeDiskObject *vnode = (struct VnodeDiskObject *)buf; diff --git a/src/vol/vol-salvage.c b/src/vol/vol-salvage.c index 375f955c6a..2f5866c7cb 100644 --- a/src/vol/vol-salvage.c +++ b/src/vol/vol-salvage.c @@ -2489,7 +2489,7 @@ JudgeEntry(void *dirVal, char *name, afs_int32 vnodeNumber, Log("dir vnode %u: %s/%s (vnode %u): unique changed from %u to %u %s\n", dir->vnodeNumber, (dir->name ? dir->name : "??"), name, vnodeNumber, unique, vnodeEssence->unique, (!todelete ? "" : (Testing ? "-- would have deleted" : "-- deleted"))); } if (!Testing) { - ViceFid fid; + AFSFid fid; fid.Vnode = vnodeNumber; fid.Unique = vnodeEssence->unique; CopyOnWrite(dir); @@ -2503,7 +2503,7 @@ JudgeEntry(void *dirVal, char *name, afs_int32 vnodeNumber, if (strcmp(name, ".") == 0) { if (dir->vnodeNumber != vnodeNumber || (dir->unique != unique)) { - ViceFid fid; + AFSFid fid; if (!Showmode) Log("directory vnode %u.%u: bad '.' entry (was %u.%u); fixed\n", dir->vnodeNumber, dir->unique, vnodeNumber, unique); if (!Testing) { @@ -2520,7 +2520,7 @@ JudgeEntry(void *dirVal, char *name, afs_int32 vnodeNumber, } dir->haveDot = 1; } else if (strcmp(name, "..") == 0) { - ViceFid pa; + AFSFid pa; if (dir->parent) { struct VnodeEssence *dotdot; pa.Vnode = dir->parent; @@ -2871,7 +2871,7 @@ SalvageVolume(register struct InodeSummary *rwIsp, IHandle_t * alinkH) afs_int32 v, pv; IHandle_t *h; afs_sfsize_t nBytes; - ViceFid pa; + AFSFid pa; VnodeId LFVnode, ThisVnode; Unique LFUnique, ThisUnique; char npath[128]; @@ -2955,7 +2955,7 @@ SalvageVolume(register struct InodeSummary *rwIsp, IHandle_t * alinkH) * won't be visible there. */ if (class == vLarge) { - ViceFid pa; + AFSFid pa; DirHandle dh; /* Remove and recreate the ".." entry in this orphaned directory */ diff --git a/src/volser/volprocs.c b/src/volser/volprocs.c index 8e34cfb4f1..cf4e46c99c 100644 --- a/src/volser/volprocs.c +++ b/src/volser/volprocs.c @@ -237,7 +237,7 @@ ViceCreateRoot(Volume *vp) { DirHandle dir; struct acl_accessList *ACL; - ViceFid did; + AFSFid did; Inode inodeNumber, nearInode; struct VnodeDiskObject *vnode; struct VnodeClassInfo *vcp = &VnodeClassInfo[vLarge];