From 515f07ef5b51445ec166caa8a2f3229ed97913ae Mon Sep 17 00:00:00 2001 From: Gonzalo de Pedro Date: Wed, 12 Dec 2018 17:11:40 -0300 Subject: [PATCH] Do not show freq parameter on help when not necessary --- image_tools/src/options.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/image_tools/src/options.cpp b/image_tools/src/options.cpp index 614570fc6..6c26fafa5 100644 --- a/image_tools/src/options.cpp +++ b/image_tools/src/options.cpp @@ -61,7 +61,9 @@ bool parse_command_options( ss << " 1 - reliable (default)" << std::endl; ss << " -d: Depth of the queue: only honored if used together with 'keep last'. " << "10 (default)" << std::endl; - ss << " -f: Publish frequency in Hz. 30 (default)" << std::endl; + if (freq != nullptr) { + ss << " -f: Publish frequency in Hz. 30 (default)" << std::endl; + } ss << " -k: History QoS setting:" << std::endl; ss << " 0 - only store up to N samples, configurable via the queue depth (default)" << std::endl;