Changeset 92883 in vbox for trunk/src/VBox
- Timestamp:
- Dec 13, 2021 1:35:00 PM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 148834
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/testdriver/vboxinstaller.py
r92330 r92883 301 301 Kills all virtual box related processes we find in the system. 302 302 """ 303 sHostOs = utils.getHostOs(); 304 asDebuggers = [ 'cdb', 'windbg', ] if sHostOs == 'windows' else [ 'gdb', 'gdb-i386-apple-darwin', 'lldb' ]; 303 305 304 306 for iIteration in range(22): 305 307 # Gather processes to kill. 306 aoTodo = []; 308 aoTodo = []; 309 aoDebuggers = []; 307 310 for oProcess in utils.processListAll(): 308 311 sBase = oProcess.getBaseImageNameNoExeSuff(); … … 316 319 if sBase.startswith('virtualbox-') and sBase.endswith('-multiarch.exe'): 317 320 aoTodo.append(oProcess); 318 if iIteration in [0, 21] and sBase in [ 'windbg', 'gdb', 'gdb-i386-apple-darwin', ]: 319 reporter.log('Warning: debugger running: %s (%s)' % (oProcess.iPid, sBase,)); 321 if sBase in asDebuggers: 322 aoDebuggers.append(oProcess); 323 if iIteration in [0, 21]: 324 reporter.log('Warning: debugger running: %s (%s %s)' % (oProcess.iPid, sBase, oProcess.asArgs)); 320 325 if not aoTodo: 321 326 return True; 327 328 # Are any of the debugger processes hooked up to a VBox process? 329 if sHostOs == 'windows': 330 # On demand debugging windows: windbg -p <decimal-pid> -e <decimal-event> -g 331 for oDebugger in aoDebuggers: 332 for oProcess in aoTodo: 333 # The whole command line is asArgs[0] here. Fix if that changes. 334 if oDebugger.asArgs and oDebugger.asArgs[0].find('-p %s ' % (oProcess.iPid,)) >= 0: 335 aoTodo.append(oDebugger); 336 break; 337 else: 338 for oDebugger in aoDebuggers: 339 for oProcess in aoTodo: 340 # Simplistic approach: Just check for argument equaling our pid. 341 if oDebugger.asArgs and ('%s' % oProcess.iPid) in oDebugger.asArgs: 342 aoTodo.append(oDebugger); 343 break; 322 344 323 345 # Kill.
Note:
See TracChangeset
for help on using the changeset viewer.