VirtualBox

Ignore:
Timestamp:
Dec 13, 2021 3:43:29 PM (3 years ago)
Author:
vboxsync
Message:

ValKit/utils.py: Made processExists work better on linux.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/common/utils.py

    r92882 r92887  
    969969    Returns True if it positively exists, False otherwise.
    970970    """
    971     if sys.platform == 'win32':
     971    sHostOs = getHostOs();
     972    if sHostOs == 'win':
    972973        fRc = False;
    973974        # We try open the process for waiting since this is generally only forbidden in a very few cases.
     
    983984            hProcess.Close();
    984985            fRc = True;
     986    elif sHostOs == 'linux':
     987        fRc = os.path.exists('/proc/%s' % (uPid,);
    985988    else:
    986989        try:
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette