VirtualBox

Changeset 27321 in vbox for trunk/src/VBox/Runtime


Ignore:
Timestamp:
Mar 12, 2010 11:10:39 AM (15 years ago)
Author:
vboxsync
Message:

process-posix.cpp: Fixed RTPROC_FLAGS_DAEMONIZE, RTProcDaemonize returns in the context of the child process.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r3/posix/process-posix.cpp

    r27287 r27321  
    302302            {
    303303                rc = RTProcDaemonize(true /* fNoChDir */, false /* fNoClose */, NULL /* pszPidFile */);
    304                 AssertReleaseMsgFailed(("RTProcDaemonize returns %Rrc errno=%d\n", rc, errno));
    305                 exit(127);
     304                if (RT_FAILURE(rc))
     305                {
     306                    AssertReleaseMsgFailed(("RTProcDaemonize returns %Rrc errno=%d\n", rc, errno));
     307                    exit(127);
     308                }
    306309            }
    307310
     
    505508
    506509    if (!fNoChDir)
     510    {
    507511        int rcChdir = chdir("/");
     512    }
    508513
    509514    /* Second fork to lose session leader status. */
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