Commit 5cff0807 authored by Gaetan Perrot's avatar Gaetan Perrot Committed by Benjamin Cabé
Browse files

samples: bluetooth: cap_acceptor: Fix shadowed variable



Avoid redeclaring 'err' inside a nested block, which shadowed the outer
definition.

This cleanup prevents confusion and potential logical bugs.

Signed-off-by: default avatarGaetan Perrot <gaetan.perrot@spacecubics.com>
parent 95d6058c
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -529,7 +529,6 @@ static void bap_pa_sync_synced_cb(struct bt_le_per_adv_sync *sync,
		atomic_clear_bit(flags, FLAG_PA_SYNCING);

		if (IS_ENABLED(CONFIG_SAMPLE_SCAN_SELF)) {
			int err;

			err = bt_le_scan_stop();
			if (err != 0) {