shithub: sox

Download patch

ref: 44f681529d002d64e6ab61d113b199313a0c1224
parent: 4b17639fb7591153dbd3e234eea21b1a2a29fcfa
author: Doug Cook <idigdoug@users.sourceforge.net>
date: Tue Mar 27 19:12:05 EDT 2012

All audio devices use "default" as the default device name.

--- a/src/sox.c
+++ b/src/sox.c
@@ -2495,13 +2495,17 @@
   if (!type)
     return NULL;
 
-  if (!strcmp(type, "sunau"))
-    name = "/dev/audio";
-  else if (!strcmp(type, "oss" ) || !strcmp(type, "ossdsp"))
-    name = "/dev/dsp";
-  else if (!strcmp(type, "alsa") || !strcmp(type, "ao") || !strcmp(type,"sndio")
-        || !strcmp(type, "coreaudio") || !strcmp(type, "pulseaudio")
-	|| !strcmp(type, "waveaudio"))
+  if (0
+      || !strcmp(type, "sunau")
+      || !strcmp(type, "oss" )
+      || !strcmp(type, "ossdsp")
+      || !strcmp(type, "alsa")
+      || !strcmp(type, "ao")
+      || !strcmp(type, "sndio")
+      || !strcmp(type, "coreaudio")
+      || !strcmp(type, "pulseaudio")
+      || !strcmp(type, "waveaudio")
+      )
     name = "default";
   
   return name? from_env? from_env : name : NULL;