summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2016-07-08 09:02:07 -0700
committerchrome-bot <chrome-bot@chromium.org>2016-07-09 01:40:43 -0700
commit9a13c52f30cd50a537b2ceeb2e5a62f398d458b6 (patch)
tree8884b051aae6fbe5e90c31551895f92fec1af07c /util
parent83a1662268c929720f1804137b49b4016a0f9766 (diff)
downloadchrome-ec-9a13c52f30cd50a537b2ceeb2e5a62f398d458b6.tar.gz
ectool: Fix uninitialized variable warning
gcc 4.8.4 warns read_buf is not initialized. This patch seizes the warning. BUG=none BRANCH=none TEST=make BOARD=stm32l476g-eval Change-Id: I07a8e01ea285e3462d6b45604350ffeab6cc00e3 Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/359002 Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'util')
-rw-r--r--util/ectool.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/ectool.c b/util/ectool.c
index 47c0303505..90d77d488a 100644
--- a/util/ectool.c
+++ b/util/ectool.c
@@ -5059,7 +5059,7 @@ int cmd_i2c_read(int argc, char *argv[])
unsigned int port, addr;
int read_len, write_len;
uint8_t write_buf[1];
- uint8_t *read_buf;
+ uint8_t *read_buf = NULL;
char *e;
int rv;