Skip to content

linux-rust: refresh the audio card index on activation#686

Open
mmatczuk wants to merge 1 commit into
librepods-org:linux/rustfrom
mmatczuk:fix/linux-refresh-card-index
Open

linux-rust: refresh the audio card index on activation#686
mmatczuk wants to merge 1 commit into
librepods-org:linux/rustfrom
mmatczuk:fix/linux-refresh-card-index

Conversation

@mmatczuk

Copy link
Copy Markdown

Summary

  • resolve the current PulseAudio/PipeWire card by Bluetooth MAC before every A2DP activation
  • update the cached card index used by subsequent profile operations
  • stop cleanly when the current card cannot be found instead of using a stale index

Validation

  • cargo check --manifest-path linux-rust/Cargo.toml
  • cargo nextest run --manifest-path linux-rust/Cargo.toml --no-tests pass

Fixes #681

PipeWire assigns a new card index when AirPods reconnect, so the cached value can point at a card that no longer exists. Resolve the card by Bluetooth MAC before every A2DP activation and update the cached index for the remaining profile operations.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant