aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2017-10-06 15:43:05 -0700
committerGravatar Craig Tiller <ctiller@google.com>2017-10-06 15:43:05 -0700
commitc128440feb62cc0fa5baa94867d14b4d564d57c3 (patch)
tree3874c0d7900bbeca1c86ca3557d33f5d5598842d
parentd48bd078d7f257db2d4c48e8e835bb2ff1ac7e73 (diff)
Fix compile error
-rw-r--r--src/core/ext/transport/chttp2/transport/flow_control.cc19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/core/ext/transport/chttp2/transport/flow_control.cc b/src/core/ext/transport/chttp2/transport/flow_control.cc
index 639e51da70..2428e2526d 100644
--- a/src/core/ext/transport/chttp2/transport/flow_control.cc
+++ b/src/core/ext/transport/chttp2/transport/flow_control.cc
@@ -399,15 +399,16 @@ static double get_pid_controller_guess(grpc_exec_ctx* exec_ctx,
if (!tfc->pid_controller_initialized) {
tfc->last_pid_update = now;
tfc->pid_controller_initialized = true;
- grpc_pid_controller_init(
- &tfc->pid_controller,
- (grpc_pid_controller_args){.gain_p = 4,
- .gain_i = 8,
- .gain_d = 0,
- .initial_control_value = target,
- .min_control_value = -1,
- .max_control_value = 25,
- .integral_range = 10});
+ grpc_pid_controller_args args;
+ memset(&args, 0, sizeof(args));
+ args.gain_p = 4;
+ args.gain_i = 8;
+ args.gain_d = 0;
+ args.initial_control_value = target;
+ args.min_control_value = -1;
+ args.max_control_value = 25;
+ args.integral_range = 10;
+ grpc_pid_controller_init(&tfc->pid_controller, args);
return pow(2, target);
}
double bdp_error = target - grpc_pid_controller_last(&tfc->pid_controller);