We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0efc950 commit ea167cfCopy full SHA for ea167cf
1 file changed
src/host/alsa/mod.rs
@@ -1670,10 +1670,12 @@ fn canonical_pcm_id(pcm_id: &str) -> String {
1670
Some((c, d)) => (c.trim(), d.trim()),
1671
None => (rest.trim(), "0"),
1672
};
1673
- if !card_str.contains('=') {
1674
- if let Ok(device) = device_str.parse::<u32>() {
1675
- return format!("{prefix}:CARD={card_str},DEV={device}");
+ if card_str.contains('=') {
+ if !rest.contains(',') {
+ return format!("{prefix}:{rest},DEV=0");
1676
}
1677
+ } else if let Ok(device) = device_str.parse::<u32>() {
1678
+ return format!("{prefix}:CARD={card_str},DEV={device}");
1679
1680
1681
pcm_id.to_owned()
0 commit comments