From 98f496011874ea441ce41c9a0de64f2feed9f52a Mon Sep 17 00:00:00 2001 From: Junhao Liao Date: Wed, 1 Oct 2025 19:49:49 -0400 Subject: [PATCH] fix: correct sparse VHD command to include `true` (#13512) * fix: correct sparse VHD command to include `true` * Revert all localization strings to f8c26f7c3 except en-US/Resources.resw * fix: run validate-localization.py with --fix option --- localization/strings/en-US/Resources.resw | 2 +- test/windows/SimpleTests.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/localization/strings/en-US/Resources.resw b/localization/strings/en-US/Resources.resw index 27a9f1a..61526d6 100644 --- a/localization/strings/en-US/Resources.resw +++ b/localization/strings/en-US/Resources.resw @@ -1108,7 +1108,7 @@ Error code: {} Sparse VHD support is currently disabled due to potential data corruption. To force a distribution to use a sparse vhd, please run: -wsl.exe --manage <DistributionName> --set-sparse --allow-unsafe +wsl.exe --manage <DistributionName> --set-sparse true --allow-unsafe {Locked="--manage "}{Locked="--set-sparse "}{Locked="--allow-unsafe"}Command line arguments, file names and string inserts should not be translated diff --git a/test/windows/SimpleTests.cpp b/test/windows/SimpleTests.cpp index 04b44fe..6adb571 100644 --- a/test/windows/SimpleTests.cpp +++ b/test/windows/SimpleTests.cpp @@ -110,7 +110,7 @@ class SimpleTests L"The operation completed successfully. \r\n", L"wsl: Sparse VHD support is currently disabled due to potential data corruption.\r\n" L"To force a distribution to use a sparse vhd, please run:\r\n" - L"wsl.exe --manage --set-sparse --allow-unsafe\r\n", + L"wsl.exe --manage --set-sparse true --allow-unsafe\r\n", 0); std::filesystem::path vhdPath = vhdDir / LXSS_VM_MODE_VHD_NAME; @@ -123,7 +123,7 @@ class SimpleTests std::format(L"{} {} {} {}", WSL_MANAGE_ARG, tempDistro, WSL_MANAGE_ARG_SET_SPARSE_OPTION_LONG, L"true").c_str(), L"Sparse VHD support is currently disabled due to potential data corruption.\r\n" L"To force a distribution to use a sparse vhd, please run:\r\n" - L"wsl.exe --manage --set-sparse --allow-unsafe\r\nError code: Wsl/Service/E_INVALIDARG\r\n", + L"wsl.exe --manage --set-sparse true --allow-unsafe\r\nError code: Wsl/Service/E_INVALIDARG\r\n", L"", -1);