VCL: close-on-empty state transition refactoring.

- Refactor session disconnect/close state
  transitions. Only remove session state
  when app calls close().  Add HUP/reset
  feedback by returning ECONNRESET.
- Update debug messages.
- Use VCL_LOCK_AND_GET_SESSION macro more
  extensively

Change-Id: I23d372834b901a6726e6d6c1061df73ad967882f
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
diff --git a/test/scripts/socket_test.sh b/test/scripts/socket_test.sh
index 110ae32..0b1f928 100755
--- a/test/scripts/socket_test.sh
+++ b/test/scripts/socket_test.sh
@@ -485,7 +485,7 @@
         pre_cmd="$gdb_in_emacs "
     elif [ $gdb -eq 1 ] ; then
         write_gdb_cmdfile $tmp_gdb_cmdfile $gdb_cmdfile $emacs $3
-        pre_cmd="gdb -x $tmp_gdb_cmdfile -i=mi --args "
+        pre_cmd="gdb -x $tmp_gdb_cmdfile --args "
     elif [ -z $3 ] ; then
         unset -v pre_cmd
     else