From 0d5777b96fec7e16dbcf2a96b285dc0ed493a34c Mon Sep 17 00:00:00 2001 From: slioch Date: Wed, 17 Jun 2009 15:07:06 -0700 Subject: ping target is now optional. nexthop will be used in place of ping target if ping target is not specified. this is also true of dhcp configurations. --- src/lboutput.cc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/lboutput.cc') diff --git a/src/lboutput.cc b/src/lboutput.cc index a20a72e..ff915ec 100644 --- a/src/lboutput.cc +++ b/src/lboutput.cc @@ -60,7 +60,12 @@ LBOutput::write(const LBData &lbdata) line += space + string("Last Status Change: ") + string(tbuf); - line += space + string("Target: Ping ") + iter->second._ping_target + "\n"; + string target = iter->second._ping_target; + if (target.empty()) { + target = iter->second._nexthop; + } + + line += space + string("Target: Ping ") + target + "\n"; char btmp[256]; string time_buf; -- cgit v1.2.3