systrace: remove the use of a Python 2.7 function

Change-Id: Ic0f4890d450541736f5909273cabcbad2ba3e3fe
diff --git a/systrace.py b/systrace.py
index 41d0cba..baafc6f 100755
--- a/systrace.py
+++ b/systrace.py
@@ -40,9 +40,16 @@
   if options.device_serial is not None:
     getprop_args[1:1] = ['-s', options.device_serial]
 
-  version = subprocess.check_output(getprop_args)
+  adb = subprocess.Popen(getprop_args, stdout=subprocess.PIPE,
+                         stderr=subprocess.PIPE)
+  out, err = adb.communicate()
+  if adb.returncode != 0:
+    print >> sys.stderr, 'Error querying device SDK-version:'
+    print >> sys.stderr, err
+    sys.exit(1)
 
-  return int(version)
+  version = int(out)
+  return version
 
 def add_adb_serial(command, serial):
   if serial != None: