(command)
| 32 | return False |
| 33 | |
| 34 | def RunWithRetunCode(command): |
| 35 | try: |
| 36 | p = subprocess.Popen(command, stdout = subprocess.PIPE, stderr = subprocess.PIPE, shell = True) |
| 37 | output = p.stdout.read() |
| 38 | p.wait() |
| 39 | errout = p.stderr.read() |
| 40 | p.stdout.close() |
| 41 | p.stderr.close() |
| 42 | return p.returncode,output,errout |
| 43 | except Exception,ex: |
| 44 | print(ex) |
| 45 | return -1,None,None |
| 46 | |
| 47 | def GetPrefixAndSuffix(host): |
| 48 | is_local = CheckLocalHost(host) |
no test coverage detected