Testrunner: Fix --gdb issue

Testrunner was eating up the output of gdb.
With the change, it will print the entire run-test script output
with --gdb.

Test: ./art/test/testrunner/testrunner.py --gdb -t 001-H

Change-Id: I35254d0a67380946e1f033ec2a46a6bf272d4adc
diff --git a/test/testrunner/testrunner.py b/test/testrunner/testrunner.py
index a809246..9a437cc 100755
--- a/test/testrunner/testrunner.py
+++ b/test/testrunner/testrunner.py
@@ -497,7 +497,11 @@
       test_skipped = True
     else:
       test_skipped = False
-      proc = subprocess.Popen(command.split(), stderr=subprocess.STDOUT, stdout=subprocess.PIPE, universal_newlines=True)
+      if gdb:
+        proc = subprocess.Popen(command.split(), stderr=subprocess.STDOUT, universal_newlines=True)
+      else:
+        proc = subprocess.Popen(command.split(), stderr=subprocess.STDOUT, stdout = subprocess.PIPE,
+                                universal_newlines=True)
       script_output = proc.communicate(timeout=timeout)[0]
       test_passed = not proc.wait()