summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Jeffrey Hutzelman <jhutz@cmu.edu>2013-02-02 09:22:07 -0500
committerGravatar Jeffrey Hutzelman <jhutz@cmu.edu>2013-02-17 22:34:40 -0500
commitf4ba8a876fe6f2d0a009362b7fa230ceb545379c (patch)
tree41ce0a891f8348d32248374d769e8bcc586ad3c9
parent9cc65a8ada2ad50d41409f1d24eb4ffb881bd492 (diff)
Dewarn realm.list enhancements
-rw-r--r--server/realm.c10
-rw-r--r--server/zserver.h1
2 files changed, 5 insertions, 6 deletions
diff --git a/server/realm.c b/server/realm.c
index ecec745..3bc72ff 100644
--- a/server/realm.c
+++ b/server/realm.c
@@ -117,9 +117,7 @@ realm_get_idx_by_addr(ZRealm *realm,
}
static int
-realm_next_idx_by_idx(realm, idx)
- ZRealm *realm;
- int idx;
+realm_next_idx_by_idx(ZRealm *realm, int idx)
{
ZRealm_server *srvr;
int a, b;
@@ -128,7 +126,7 @@ realm_next_idx_by_idx(realm, idx)
srvr = realm->srvrs; a = idx;
while (a > 0) { a--; srvr++; }
- for (srvr, b = idx; b < realm->count; b++, srvr++) {
+ for (b = idx; b < realm->count; b++, srvr++) {
if (!is_usable(srvr))
continue;
if (!srvr->dontsend)
@@ -385,12 +383,12 @@ realm_get_realm_by_name(char *name)
}
ZRealm *
-realm_get_realm_by_name_string(String *z)
+realm_get_realm_by_name_string(String *namestr)
{
int a;
for (a = 0; a < nrealms; a++)
- if (otherrealms[a]->namestr == z)
+ if (otherrealms[a]->namestr == namestr)
return otherrealms[a];
return 0;
diff --git a/server/zserver.h b/server/zserver.h
index ae509ab..5249f86 100644
--- a/server/zserver.h
+++ b/server/zserver.h
@@ -369,6 +369,7 @@ int realm_sender_in_realm(const char *realm, char *sender);
int realm_bound_for_realm(const char *realm, char *recip);
ZRealm *realm_which_realm(struct sockaddr_in *who);
ZRealm *realm_get_realm_by_name(char *name);
+ZRealm *realm_get_realm_by_name_string(String *namestr);
ZRealm *realm_get_realm_by_pid(int);
void realm_handoff(ZNotice_t *, int, struct sockaddr_in *, ZRealm *, int);
const char *realm_expand_realm(char *);