diff options
author | Christian Pointner <equinox@helsinki.at> | 2010-01-10 13:56:57 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2010-01-10 13:56:57 (GMT) |
commit | 51af8e19e9ad47539038f04012f4202f2dbb6b9a (patch) | |
tree | 0b432b9dd29d62e2f903af1e41df49d623a29ed1 | |
parent | 2532c73e35f699b366ca682bc058dc86c4660b5b (diff) |
type master and standby now implicit sets gpi listener flag
-rw-r--r-- | openwrt/rhctl/Makefile | 2 | ||||
-rw-r--r-- | switchctl.c | 10 |
2 files changed, 8 insertions, 4 deletions
diff --git a/openwrt/rhctl/Makefile b/openwrt/rhctl/Makefile index 58a7e56..7071bb1 100644 --- a/openwrt/rhctl/Makefile +++ b/openwrt/rhctl/Makefile @@ -18,7 +18,7 @@ PKG_RELEASE:=1 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=http://localhost/ -PKG_MD5SUM:=b78c565d316a4d18c5b0959db3895576 +PKG_MD5SUM:=eb7c44c6c95da63480440799d3f72041 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install diff --git a/switchctl.c b/switchctl.c index b003909..6d5c42c 100644 --- a/switchctl.c +++ b/switchctl.c @@ -312,10 +312,14 @@ void process_cmd_type(const char* param, int fd, client_t* client_lst) if(param) { client_t* client = client_find(client_lst, fd); if(client) { - if(!strncmp(param, "master", 6)) + if(!strncmp(param, "master", 6)) { client->type = MASTER; - else if(!strncmp(param, "standby", 7)) - client->type = STANDBY; + client->gpi_listener = 1; + } + else if(!strncmp(param, "standby", 7)) { + client->type = STANDBY; + client->gpi_listener = 1; + } else if(!strncmp(param, "heartbeat", 9)) client->type = HEARTBEAT; else { |