From 845fdcac4197cf11ec847ccadc6e3c2f4601358a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herm=C3=A8s=20B=C3=A9lusca-Ma=C3=AFto?= Date: Fri, 12 Jun 2015 01:19:19 +0000 Subject: [PATCH] [NTVDM]: The DOS session ID specified in the NTVDM command line is in hexadecimal format (and not decimal!). Fixes NTVDM start with double-click after 9-10 launches, on ROS and Windows. svn path=/trunk/; revision=68108 --- reactos/subsystems/mvdm/ntvdm/dos/dem.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/reactos/subsystems/mvdm/ntvdm/dos/dem.c b/reactos/subsystems/mvdm/ntvdm/dos/dem.c index 281dc79744a..dabee5d041f 100644 --- a/reactos/subsystems/mvdm/ntvdm/dos/dem.c +++ b/reactos/subsystems/mvdm/ntvdm/dos/dem.c @@ -461,8 +461,8 @@ static VOID WINAPI DosStart(LPWORD Stack) { if (wcsncmp(NtVdmArgv[i], L"-i", 2) == 0) { - /* This is the session ID */ - SessionId = wcstoul(NtVdmArgv[i] + 2, NULL, 10); + /* This is the session ID (hex format) */ + SessionId = wcstoul(NtVdmArgv[i] + 2, NULL, 16); /* The VDM hasn't been started from a console, so quit when the task is done */ AcceptCommands = FALSE;