From eb52c24a03c9995d989356c0ae05730ea8da9ce7 Mon Sep 17 00:00:00 2001 From: Yannick Brosseau Date: Wed, 23 Feb 2011 00:30:30 +0100 Subject: [PATCH] Initialize _res_header variable to zero before use in process_client_cmd This use of a non-initialized variable was detected by the valgrind test. Signed-off-by: Yannick Brosseau Acked-by: Nils Carlson --- libustconsumer/libustconsumer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libustconsumer/libustconsumer.c b/libustconsumer/libustconsumer.c index 25c84ce0..c51b1066 100644 --- a/libustconsumer/libustconsumer.c +++ b/libustconsumer/libustconsumer.c @@ -621,7 +621,7 @@ static void process_client_cmd(int sock, struct ustcomm_header *req_header, char *recvbuf, struct ustconsumer_instance *instance) { int result; - struct ustcomm_header _res_header; + struct ustcomm_header _res_header = {0}; struct ustcomm_header *res_header = &_res_header; struct ustcomm_buffer_info *buf_inf; -- 2.34.1