diff options
author | Dan Winship <danw@mit.edu> | 1999-08-12 20:18:50 +0000 |
---|---|---|
committer | Dan Winship <danw@mit.edu> | 1999-08-12 20:18:50 +0000 |
commit | fec950e474e5f7a177353db7b13f5818875741dd (patch) | |
tree | 92a738afb94b295ffe3a10da1d253752dcb10864 /clients | |
parent | 2039591aa7030cca31327a66c78f0a4b2bcccfb3 (diff) |
fix things that Irix n32 cc warns about, possibly including the bug
that makes zstat randomly dump core some times
Diffstat (limited to 'clients')
-rw-r--r-- | clients/zstat/zstat.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/clients/zstat/zstat.c b/clients/zstat/zstat.c index f378771..0c034f9 100644 --- a/clients/zstat/zstat.c +++ b/clients/zstat/zstat.c @@ -44,14 +44,16 @@ const char *srv_head[] = { int outoftime = 0; +int serveronly = 0,hmonly = 0; +u_short srv_port; + +void usage(), do_stat(); + RETSIGTYPE timeout() { outoftime = 1; } -int serveronly = 0,hmonly = 0; -u_short srv_port; - main(argc, argv) int argc; char *argv[]; @@ -111,6 +113,7 @@ main(argc, argv) exit(0); } +void do_stat(host) char *host; { @@ -128,6 +131,7 @@ do_stat(host) (void) srv_stat(srv_host); } +int hm_stat(host,server) char *host,*server; { @@ -135,7 +139,7 @@ hm_stat(host,server) Code_t code; char *line[20],*mp; - int sock,i,nf,ret; + int i,nf; struct hostent *hp; time_t runtime; struct tm *tim; @@ -157,7 +161,7 @@ hm_stat(host,server) } if ((code = ZhmStat(&inaddr, ¬ice)) != ZERR_NONE) { - com_err("zstat", ret, "getting hostmanager status"); + com_err("zstat", code, "getting hostmanager status"); exit(-1); } @@ -187,11 +191,11 @@ hm_stat(host,server) printf("\n"); - (void) close(sock); ZFreeNotice(¬ice); return(0); } +int srv_stat(host) char *host; { @@ -303,6 +307,7 @@ srv_stat(host) return(0); } +void usage(s) char *s; { |