Skip to content

Commit 09546ff

Browse files
larsgkmmahadevan108
authored andcommitted
Bluetooth: Shell: Set err to 0 before shell_strtoul
The value of err was not initialized to 0 prior to calling shell_strtoul, which only sets err on actual error. Signed-off-by: Lars Knudsen <[email protected]>
1 parent cd3dcf7 commit 09546ff

File tree

1 file changed

+1
-0
lines changed
  • subsys/bluetooth/host/shell

1 file changed

+1
-0
lines changed

subsys/bluetooth/host/shell/iso.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -806,6 +806,7 @@ static int cmd_big_sync(const struct shell *sh, size_t argc, char *argv[])
806806
return -ENOEXEC;
807807
}
808808

809+
err = 0;
809810
bis_bitfield = shell_strtoul(argv[1], 0, &err);
810811
if (err != 0) {
811812
shell_error(sh, "Could not parse bis_bitfield: %d", err);

0 commit comments

Comments
 (0)