diff options
author | 2015-11-15 18:17:13 +0200 | |
---|---|---|
committer | 2015-11-15 18:17:13 +0200 | |
commit | f9365e5150f9479dfbf4436d22874f121afbb5c8 (patch) | |
tree | f97b9dfd52b880eeab0aba631e74231abdb851f1 /src/rpc-server/commands/trex_rpc_cmd_stream.cpp | |
parent | 8017ebe740a1c1d138559795aea9d8ee72236da2 (diff) | |
parent | 94b1238942da24e47fb3e689bf695e815a604eb0 (diff) |
Merge branch 'rpc_intg1'
Diffstat (limited to 'src/rpc-server/commands/trex_rpc_cmd_stream.cpp')
-rw-r--r-- | src/rpc-server/commands/trex_rpc_cmd_stream.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/rpc-server/commands/trex_rpc_cmd_stream.cpp b/src/rpc-server/commands/trex_rpc_cmd_stream.cpp index e32073b0..5ec92afc 100644 --- a/src/rpc-server/commands/trex_rpc_cmd_stream.cpp +++ b/src/rpc-server/commands/trex_rpc_cmd_stream.cpp @@ -458,8 +458,9 @@ TrexRpcCmdGetStream::_run(const Json::Value ¶ms, Json::Value &result) { trex_rpc_cmd_rc_e TrexRpcCmdStartTraffic::_run(const Json::Value ¶ms, Json::Value &result) { - uint8_t port_id = parse_byte(params, "port_id", result); - double mul = parse_double(params, "mul", result); + uint8_t port_id = parse_byte(params, "port_id", result); + double mul = parse_double(params, "mul", result); + double duration = parse_double(params, "duration", result); if (port_id >= get_stateless_obj()->get_port_count()) { std::stringstream ss; @@ -470,7 +471,7 @@ TrexRpcCmdStartTraffic::_run(const Json::Value ¶ms, Json::Value &result) { TrexStatelessPort *port = get_stateless_obj()->get_port_by_id(port_id); try { - port->start_traffic(mul); + port->start_traffic(mul, duration); } catch (const TrexRpcException &ex) { generate_execute_err(result, ex.what()); } |