Bluetooth: Fix initialization of variable

Initialize the variable to zero before computing.

Change-Id: Iccdf77a085667728dbb68779f001c8d940a7a89d
Signed-off-by: Sathish Narasimman <sathish.narasimman@intel.com>
This commit is contained in:
Sathish Narasimman 2016-11-03 20:12:56 +05:30 committed by Johan Hedberg
commit 56392e5c2e

View file

@ -50,6 +50,8 @@ const char *skip_whitespace(const char *buf)
int at_get_number(const char *buf, uint32_t *val)
{
*val = 0;
for (buf = skip_whitespace(buf); isdigit(*buf); buf++) {
*val = *val * 10 + *buf - '0';
}