Changeset 34709 in vbox
- Timestamp:
- Dec 3, 2010 5:38:01 PM (14 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxService/VBoxServiceControlExec.cpp
r34255 r34709 1210 1210 if (RT_SUCCESS(rc)) 1211 1211 { 1212 /* If no user name specified run with current credentials. 1213 * This is prohibited via official Main API! */ 1214 if (!strlen(pszAsUser)) 1215 fFlags &= ~RTPROC_FLAGS_SERVICE; 1212 uint32_t uProcFlags = 0; 1213 if (fFlags) 1214 { 1215 /* Process Main flag "ExecuteProcessFlag_Hidden". */ 1216 if (fFlags & RT_BIT(2)) 1217 uProcFlags = RTPROC_FLAGS_HIDDEN; 1218 } 1219 1220 /* If no user name specified run with current credentials (e.g. 1221 * full service/system rights). This is prohibited via official Main API! 1222 * 1223 * Otherwise use the RTPROC_FLAGS_SERVICE to use some special authentication 1224 * code (at least on Windows) for running processes as different users 1225 * started from our system service. */ 1226 if (strlen(pszAsUser)) 1227 uProcFlags |= RTPROC_FLAGS_SERVICE; 1216 1228 1217 1229 /* Do normal execution. */ 1218 rc = RTProcCreateEx(szExecExp, papszArgsExp, hEnv, fFlags,1230 rc = RTProcCreateEx(szExecExp, papszArgsExp, hEnv, uProcFlags, 1219 1231 phStdIn, phStdOut, phStdErr, 1220 1232 strlen(pszAsUser) ? pszAsUser : NULL, … … 1308 1320 { 1309 1321 RTPROCESS hProcess; 1310 rc = VBoxServiceControlExecCreateProcess(pData->pszCmd, pData->papszArgs, hEnv, RTPROC_FLAGS_SERVICE,1322 rc = VBoxServiceControlExecCreateProcess(pData->pszCmd, pData->papszArgs, hEnv, pData->uFlags, 1311 1323 phStdIn, phStdOut, phStdErr, 1312 1324 pData->pszUser, pData->pszPassword, -
trunk/src/VBox/Frontends/VBoxManage/VBoxManageGuestCtrl.cpp
r34660 r34709 349 349 case 'f': /* Flags */ 350 350 /** @todo Needs a bit better processing as soon as we have more flags. */ 351 /** @todo Add a hidden flag. */ 351 352 if (!RTStrICmp(ValueUnion.psz, "ignoreorphanedprocesses")) 352 353 uFlags |= ExecuteProcessFlag_IgnoreOrphanedProcesses; -
trunk/src/VBox/Main/GuestImpl.cpp
r34619 r34709 263 263 */ 264 264 rc = pGuest->executeProcessInternal(Bstr(VBOXSERVICE_TOOL_CAT).raw(), 265 ExecuteProcessFlag_WaitForProcessStartOnly, 265 ExecuteProcessFlag_Hidden 266 | ExecuteProcessFlag_WaitForProcessStartOnly, 266 267 ComSafeArrayAsInParam(args), 267 268 ComSafeArrayAsInParam(env), … … 410 411 /* 411 412 * Start the just copied over installer with system rights 412 * in silent mode on the guest. 413 * in silent mode on the guest. Don't use the hidden flag since there 414 * may be pop ups the user has to process. 413 415 */ 414 416 ComPtr<IProgress> progressInstaller; … … 1597 1599 { 1598 1600 if ( !(aFlags & ExecuteProcessFlag_IgnoreOrphanedProcesses) 1599 && !(aFlags & ExecuteProcessFlag_WaitForProcessStartOnly)) 1601 && !(aFlags & ExecuteProcessFlag_WaitForProcessStartOnly) 1602 && !(aFlags & ExecuteProcessFlag_Hidden)) 1600 1603 { 1601 1604 if (pRC) … … 2434 2437 */ 2435 2438 rc = ExecuteProcess(Bstr(VBOXSERVICE_TOOL_CAT).raw(), 2436 ExecuteProcessFlag_WaitForProcessStartOnly, 2439 ExecuteProcessFlag_Hidden 2440 | ExecuteProcessFlag_WaitForProcessStartOnly, 2437 2441 ComSafeArrayAsInParam(args), 2438 2442 ComSafeArrayAsInParam(env), … … 2591 2595 { 2592 2596 rc = ExecuteProcess(Bstr(VBOXSERVICE_TOOL_MKDIR).raw(), 2593 ExecuteProcessFlag_ None,2597 ExecuteProcessFlag_Hidden, 2594 2598 ComSafeArrayAsInParam(args), 2595 2599 ComSafeArrayAsInParam(env), -
trunk/src/VBox/Main/idl/VirtualBox.xidl
r34587 r34709 7871 7871 <desc>Do not report an error when executed processes are still alive when VBoxService or the guest OS is shutting down.</desc> 7872 7872 </const> 7873 7874 <const name="Hidden" value="4"> 7875 <desc>Don't show the started process according to the guest OS guidelines.</desc> 7876 </const> 7873 7877 </enum> 7874 7878
Note:
See TracChangeset
for help on using the changeset viewer.