[PC-BSD Commits] r19921 - pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts

svn at pcbsd.org svn at pcbsd.org
Thu Oct 25 06:31:41 PDT 2012


Author: kris
Date: 2012-10-25 13:31:41 +0000 (Thu, 25 Oct 2012)
New Revision: 19921

Modified:
   pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh
Log:

Make sure to only set device which has "playback" enabled



Modified: pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh
===================================================================
--- pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh	2012-10-25 09:18:44 UTC (rev 19920)
+++ pcbsd/current/overlays/desktop-overlay/usr/local/share/pcbsd/scripts/sound-dev-changed.sh	2012-10-25 13:31:41 UTC (rev 19921)
@@ -63,7 +63,7 @@
 set_new_dev()
 {
    # Get the last pcm device so we can make it the default
-   newDev=`cat /dev/sndstat | egrep -o 'pcm[0-9]+' | tail -n 1`
+   newDev=`cat /dev/sndstat | grep play | egrep -o 'pcm[0-9]+' | tail -n 1`
    dNum=`echo $newDev | sed 's|pcm||g'`
    sysctl hw.snd.default_unit=$dNum
 }



More information about the Commits mailing list