Skip to content

Commit

Permalink
fix for finding ALSA hotplug devices on Steam Link
Browse files Browse the repository at this point in the history
James Zipperer

The device names show up as "default:", not "hw:"
  • Loading branch information
slouken committed Oct 6, 2016
1 parent 9257b72 commit 8e19946
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/audio/alsa/SDL_alsa_audio.c
Expand Up @@ -779,7 +779,8 @@ ALSA_HotplugThread(void *arg)
}

/* only want physical hardware interfaces */
if (SDL_strncmp(name, "hw:", 3) == 0) {
if (SDL_strncmp(name, "hw:", 3) == 0 ||
SDL_strncmp(name, "default:", 8) == 0) {
char *ioid = ALSA_snd_device_name_get_hint(hints[i], "IOID");
const SDL_bool isoutput = (ioid == NULL) || (SDL_strcmp(ioid, "Output") == 0);
const SDL_bool isinput = (ioid == NULL) || (SDL_strcmp(ioid, "Input") == 0);
Expand Down

0 comments on commit 8e19946

Please sign in to comment.