From 8553a8d63f97cfa8d64b5b2260e81f8c896a8398 Mon Sep 17 00:00:00 2001
From: nancy.liao <huihui.liao@greentest.com.cn>
Date: 周五, 23 5月 2025 18:36:03 +0800
Subject: [PATCH] 修改部分因为标准原因的报错

---
 src/library/os/windows/execution_environment.cpp |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/library/os/windows/execution_environment.cpp b/src/library/os/windows/execution_environment.cpp
index 50a255e..7423e9b 100644
--- a/src/library/os/windows/execution_environment.cpp
+++ b/src/library/os/windows/execution_environment.cpp
@@ -30,8 +30,7 @@
 
 	CONTAINER_TYPE result = CONTAINER_TYPE::NONE;
 	const DWORD dwResult = GetLogicalDriveStrings(dwSize, szLogicalDrives);
-	
-	//FIXME! this code missed the increment in the loop... 
+
 	if (dwResult > 0 && dwResult <= MAX_PATH) {
 		char* szSingleDrive = szLogicalDrives;
 		while (*szSingleDrive && ndrives < MAX_UNITS) {
@@ -57,6 +56,8 @@
 					// no problem,we're just guessing
 				}
 			}
+			szSingleDrive += strlen(szSingleDrive) + 1;
+			ndrives++;
 		}
 	}
 	return result;

--
Gitblit v1.9.1