X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=utils%2Fstatd%2Fmonitor.c;h=3b81bdd4af1a6cc829cc9efc0d6a2c8e5ddd3d11;hp=8c1bb50ef98a076aadb00ecc3dbf2f66882e3a28;hb=af93e0306d87bba3f703386fd6390e9bf8e76816;hpb=2c91715a9c8dbf18df1666f70e78d6e36e123ca0 diff --git a/utils/statd/monitor.c b/utils/statd/monitor.c index 8c1bb50..3b81bdd 100644 --- a/utils/statd/monitor.c +++ b/utils/statd/monitor.c @@ -19,6 +19,7 @@ #include "misc.h" #include "statd.h" #include "notlist.h" +#include "ha-callout.h" notify_list * rtnl = NULL; /* Run-time notify list. */ @@ -177,6 +178,8 @@ sm_mon_1_svc(struct mon *argp, struct svc_req *rqstp) goto failure; } free(path); + /* PRC: do the HA callout: */ + ha_callout("add-client", mon_name, my_name, -1); nlist_insert(&rtnl, clnt); close(fd); @@ -232,6 +235,10 @@ sm_unmon_1_svc(struct mon_id *argp, struct svc_req *rqstp) /* Match! */ dprintf(N_DEBUG, "UNMONITORING %s for %s", mon_name, my_name); + + /* PRC: do the HA callout: */ + ha_callout("del-client", mon_name, my_name, -1); + nlist_free(&rtnl, clnt); xunlink(SM_DIR, mon_name, 1); @@ -276,6 +283,8 @@ sm_unmon_all_1_svc(struct my_id *argp, struct svc_req *rqstp) sizeof (mon_name) - 1); mon_name[sizeof (mon_name) - 1] = '\0'; temp = NL_NEXT(clnt); + /* PRC: do the HA callout: */ + ha_callout("del-client", mon_name, argp->my_name, -1); nlist_free(&rtnl, clnt); xunlink(SM_DIR, mon_name, 1); ++count;