From 1c97582ecb99e9cadb0a4dfceaeda6c4c12e8397 Mon Sep 17 00:00:00 2001 From: pjd Date: Fri, 28 Jan 2011 21:57:42 +0000 Subject: Use newly added descriptors_assert() function to ensure only expected descriptors are open. MFC after: 1 week --- sbin/hastd/primary.c | 2 ++ sbin/hastd/secondary.c | 2 ++ 2 files changed, 4 insertions(+) (limited to 'sbin') diff --git a/sbin/hastd/primary.c b/sbin/hastd/primary.c index 94fbe34..e22ef82 100644 --- a/sbin/hastd/primary.c +++ b/sbin/hastd/primary.c @@ -837,6 +837,8 @@ hastd_primary(struct hast_resource *res) proto_recv(res->hr_ctrl, NULL, 0); descriptors_cleanup(res); + descriptors_assert(res, mode); + pjdlog_init(mode); pjdlog_prefix_set("[%s] (%s) ", res->hr_name, role2str(res->hr_role)); setproctitle("%s (primary)", res->hr_name); diff --git a/sbin/hastd/secondary.c b/sbin/hastd/secondary.c index ae11792..821d5c7 100644 --- a/sbin/hastd/secondary.c +++ b/sbin/hastd/secondary.c @@ -395,6 +395,8 @@ hastd_secondary(struct hast_resource *res, struct nv *nvin) proto_recv(res->hr_ctrl, NULL, 0); descriptors_cleanup(res); + descriptors_assert(res, mode); + pjdlog_init(mode); pjdlog_prefix_set("[%s] (%s) ", res->hr_name, role2str(res->hr_role)); setproctitle("%s (secondary)", res->hr_name); -- cgit v1.1