msi: Implement MsiGet/SetMode(MSIRUNMODE_REBOOTNOW).
This commit is contained in:
parent
a6b3d77021
commit
15ee85dee8
|
@ -764,6 +764,10 @@ BOOL WINAPI MsiGetMode(MSIHANDLE hInstall, MSIRUNMODE iRunMode)
|
|||
r = package->need_reboot_at_end;
|
||||
break;
|
||||
|
||||
case MSIRUNMODE_REBOOTNOW:
|
||||
r = package->need_reboot_now;
|
||||
break;
|
||||
|
||||
case MSIRUNMODE_LOGENABLED:
|
||||
r = (package->log_file != INVALID_HANDLE_VALUE);
|
||||
break;
|
||||
|
@ -819,8 +823,8 @@ UINT WINAPI MsiSetMode(MSIHANDLE hInstall, MSIRUNMODE iRunMode, BOOL fState)
|
|||
break;
|
||||
|
||||
case MSIRUNMODE_REBOOTNOW:
|
||||
FIXME("unimplemented run mode: %d\n", iRunMode);
|
||||
r = ERROR_FUNCTION_FAILED;
|
||||
package->need_reboot_now = (fState != 0);
|
||||
r = ERROR_SUCCESS;
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
|
@ -407,6 +407,7 @@ typedef struct tagMSIPACKAGE
|
|||
unsigned char commit_action_running : 1;
|
||||
unsigned char rollback_action_running : 1;
|
||||
unsigned char need_reboot_at_end : 1;
|
||||
unsigned char need_reboot_now : 1;
|
||||
unsigned char need_rollback : 1;
|
||||
} MSIPACKAGE;
|
||||
|
||||
|
|
|
@ -1887,7 +1887,7 @@ static void test_Session(IDispatch *pSession)
|
|||
ok(hr == S_OK, "Session_ModePut failed, hresult 0x%08x\n", hr);
|
||||
|
||||
hr = Session_ModePut(pSession, MSIRUNMODE_REBOOTNOW, TRUE);
|
||||
todo_wine ok(hr == S_OK, "Session_ModePut failed, hresult 0x%08x\n", hr);
|
||||
ok(hr == S_OK, "Session_ModePut failed, hresult 0x%08x\n", hr);
|
||||
if (hr == DISP_E_EXCEPTION) ok_exception(hr, szModeFlag);
|
||||
|
||||
hr = Session_ModeGet(pSession, MSIRUNMODE_REBOOTNOW, &bool);
|
||||
|
@ -1895,7 +1895,7 @@ static void test_Session(IDispatch *pSession)
|
|||
ok(bool, "Reboot now mode is %d, expected 1\n", bool);
|
||||
|
||||
hr = Session_ModePut(pSession, MSIRUNMODE_REBOOTNOW, FALSE); /* set it again so we don't reboot */
|
||||
todo_wine ok(hr == S_OK, "Session_ModePut failed, hresult 0x%08x\n", hr);
|
||||
ok(hr == S_OK, "Session_ModePut failed, hresult 0x%08x\n", hr);
|
||||
if (hr == DISP_E_EXCEPTION) ok_exception(hr, szModeFlag);
|
||||
|
||||
hr = Session_ModePut(pSession, MSIRUNMODE_MAINTENANCE, TRUE);
|
||||
|
|
Loading…
Reference in New Issue