diff options
author | Jett Rink <jettrink@chromium.org> | 2020-11-10 17:10:57 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2020-11-11 18:37:36 +0000 |
commit | e2dfdb09d970143b521a9c6f316ebe09159988ed (patch) | |
tree | 02fc659853834812b28387060aed74e0ad722bdb /util/lbcc.c | |
parent | 737d4205a62c4b70ad33a6fbd547f5cb3f2b888c (diff) | |
download | chrome-ec-e2dfdb09d970143b521a9c6f316ebe09159988ed.tar.gz |
tree: rename strtoul to strtoull since it is 64-bit
A long is 32-bit, but a long long is 64-bit. The function name should be
strtoull if it is returning 64 bits of data.
BRANCH=none
BUG=b:172592963
TEST=builds
Signed-off-by: Jett Rink <jettrink@chromium.org>
Change-Id: I04c40f9256ed37eb1cf9b6bd1b0ef0320fe49b0c
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2530874
Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Diffstat (limited to 'util/lbcc.c')
-rw-r--r-- | util/lbcc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util/lbcc.c b/util/lbcc.c index 1a201e90d8..c0bde684da 100644 --- a/util/lbcc.c +++ b/util/lbcc.c @@ -291,7 +291,7 @@ static int split_line(char *buf, char *delim, struct parse_s *elt, int max) i < max && (w = strtok_r(ptr, delim, &buf_savetok)) != 0; ptr = 0, i++) { elt[i].word = w; - elt[i].val = (uint32_t)strtoul(w, &e, 0); + elt[i].val = (uint32_t)strtoull(w, &e, 0); if (!e || !*e) elt[i].is_num = 1; @@ -315,7 +315,7 @@ static int is_led_set(char *buf, uint8_t *valp) buf++; for (;;) { - next_led = strtoul(buf, &ptr, 0); + next_led = strtoull(buf, &ptr, 0); if (buf == ptr) { if (buf[0] == '}' && buf[1] == 0) { *valp = led; |