From e117599fe17fdfca9c61d1883fe9bf9aa95e3918 Mon Sep 17 00:00:00 2001 From: Derrick Brashear Date: Tue, 4 Jul 2006 04:57:05 +0000 Subject: [PATCH] fileserver-hates-pruclient-20060626 right now there is one struct ubik_client shared by all threads in the fileserve r, which sucks when one has it locked let's, uh, fix that. --- src/ptserver/ptprocs.c | 14 -------------- src/ptserver/ptuser.c | 11 ----------- src/util/casestrcpy.c | 22 ++++++++++++++++++++++ 3 files changed, 22 insertions(+), 25 deletions(-) diff --git a/src/ptserver/ptprocs.c b/src/ptserver/ptprocs.c index 0753bf231c..f08a82b67e 100644 --- a/src/ptserver/ptprocs.c +++ b/src/ptserver/ptprocs.c @@ -104,7 +104,6 @@ afs_int32 listElements(), listOwned(), isAMemberOf(), idToName(); afs_int32 listSuperGroups(); #endif -static stolower(); extern int IDCmp(); extern int prp_group_default; @@ -2217,19 +2216,6 @@ isAMemberOf(call, uid, gid, flag, cid) return code; } - -static -stolower(s) - register char *s; -{ - register int tc; - while ((tc = *s)) { - if (isupper(tc)) - *s = tolower(tc); - s++; - } -} - #if IP_WILDCARDS afs_int32 addWildCards(tt, alist, host) diff --git a/src/ptserver/ptuser.c b/src/ptserver/ptuser.c index 79e895e69e..26791f4ff3 100644 --- a/src/ptserver/ptuser.c +++ b/src/ptserver/ptuser.c @@ -765,14 +765,3 @@ pr_SetFieldsEntry(afs_int32 id, afs_int32 mask, afs_int32 flags, afs_int32 ngrou nusers, 0, 0); return code; } - -int -stolower(char *s) -{ - while (*s) { - if (isupper(*s)) - *s = tolower(*s); - s++; - } - return 0; -} diff --git a/src/util/casestrcpy.c b/src/util/casestrcpy.c index b715ee8665..4645d1f3b1 100644 --- a/src/util/casestrcpy.c +++ b/src/util/casestrcpy.c @@ -67,6 +67,28 @@ ucstring(char *d, char *s, int n) return original_d; } +int +stolower(char *s) +{ + while (*s) { + if (isupper(*s)) + *s = tolower(*s); + s++; + } + return 0; +} + +int +stoupper(char *s) +{ + while (*s) { + if (islower(*s)) + *s = toupper(*s); + s++; + } + return 0; +} + /* strcompose - concatenate strings passed to it. * Input: * buf: storage for the composed string. Any data in it will be lost.