aboutsummaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2020-10-31 15:53:54 +0100
committerSimon Rozman <simon@rozman.si>2020-10-31 19:11:56 +0100
commit378e8eec27289bf2e740badb7565262471133376 (patch)
treebe99ee7910615d2a78b0b6884d3daa77541bcbe7 /api
parentapi: do not require RebootRequired (diff)
downloadwintun-378e8eec27289bf2e740badb7565262471133376.tar.xz
wintun-378e8eec27289bf2e740badb7565262471133376.zip
api: clear up argument evaluation order
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'api')
-rw-r--r--api/rundll32.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/api/rundll32.c b/api/rundll32.c
index a397501..dce1bd6 100644
--- a/api/rundll32.c
+++ b/api/rundll32.c
@@ -138,11 +138,8 @@ VOID __stdcall DeleteAdapter(HWND hwnd, HINSTANCE hinst, LPSTR lpszCmdLine, int
if (FAILED(CLSIDFromString(Argv[3], &Adapter.CfgInstanceID)))
goto cleanup;
BOOL RebootRequired;
- WriteFormatted(
- STD_OUTPUT_HANDLE,
- L"%1!X! %2!X!",
- WintunDeleteAdapter(&Adapter, ForceCloseSessions, &RebootRequired),
- RebootRequired);
+ WINTUN_STATUS Ret = WintunDeleteAdapter(&Adapter, ForceCloseSessions, &RebootRequired);
+ WriteFormatted(STD_OUTPUT_HANDLE, L"%1!X! %2!X!", Ret, RebootRequired);
cleanup:
Done();