Switch to side-by-side view

--- a/sc2src/alsadirect.cpp
+++ b/sc2src/alsadirect.cpp
@@ -297,6 +297,12 @@
 error:
     LOGERR("alsa_init: " << cmd << " error:" << snd_strerror(err) << endl);
     return false;
+}
+
+static void alsa_close()
+{
+    LOGDEB("alsawriter: alsa close\n");
+    snd_pcm_close(pcm);
 }
 
 // Current in-driver delay in samples
@@ -742,6 +748,7 @@
     alsaqueue.setTerminateAndWait();
 alsaerror:
     queue->workerExit();
+    alsa_close();
 
     if (src_state) {
         if (cvt_type != -1) {