Skip to content

Commit ce6d0d5

Browse files
authored
Fix debug build with latest VS version (#5461)
The u8"" string literal causes a new compiler warning 5321 with latest update, disable it in the project level. Also updated fuzzing path, again.
1 parent 1b24d12 commit ce6d0d5

File tree

9 files changed

+29
-20
lines changed

9 files changed

+29
-20
lines changed

.github/actions/spelling/expect.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ Dcom
116116
debian
117117
decompressor
118118
dedupe
119+
DEFT
119120
deigh
120121
deleteifnotneeded
121122
deliveryoptimization

src/AppInstallerCLI.sln

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -606,23 +606,23 @@ Global
606606
{846FB88B-BF1B-4F33-9883-E589CEC99739}.TestRelease|ARM64.ActiveCfg = Release|Any CPU
607607
{846FB88B-BF1B-4F33-9883-E589CEC99739}.TestRelease|x64.ActiveCfg = Release|Any CPU
608608
{846FB88B-BF1B-4F33-9883-E589CEC99739}.TestRelease|x86.ActiveCfg = Release|Any CPU
609-
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|ARM64.ActiveCfg = Debug|ARM64
609+
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|ARM64.ActiveCfg = Debug|x64
610610
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|x64.ActiveCfg = Debug|x64
611611
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|x64.Build.0 = Debug|x64
612612
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|x86.ActiveCfg = Debug|x86
613613
{68808357-902B-406C-8C19-E8E26A69DE8A}.Debug|x86.Build.0 = Debug|x86
614-
{68808357-902B-406C-8C19-E8E26A69DE8A}.Fuzzing|ARM64.ActiveCfg = Release|Any CPU
615-
{68808357-902B-406C-8C19-E8E26A69DE8A}.Fuzzing|x64.ActiveCfg = Release|Any CPU
614+
{68808357-902B-406C-8C19-E8E26A69DE8A}.Fuzzing|ARM64.ActiveCfg = Release|x64
615+
{68808357-902B-406C-8C19-E8E26A69DE8A}.Fuzzing|x64.ActiveCfg = Release|x64
616616
{68808357-902B-406C-8C19-E8E26A69DE8A}.Fuzzing|x86.ActiveCfg = Release|x86
617-
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|ARM64.ActiveCfg = Release|ARM64
617+
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|ARM64.ActiveCfg = Release|x64
618618
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|x64.ActiveCfg = Release|x64
619619
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|x64.Build.0 = Release|x64
620620
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|x86.ActiveCfg = Release|x86
621621
{68808357-902B-406C-8C19-E8E26A69DE8A}.Release|x86.Build.0 = Release|x86
622-
{68808357-902B-406C-8C19-E8E26A69DE8A}.ReleaseStatic|ARM64.ActiveCfg = Release|Any CPU
623-
{68808357-902B-406C-8C19-E8E26A69DE8A}.ReleaseStatic|x64.ActiveCfg = Release|Any CPU
622+
{68808357-902B-406C-8C19-E8E26A69DE8A}.ReleaseStatic|ARM64.ActiveCfg = Release|x64
623+
{68808357-902B-406C-8C19-E8E26A69DE8A}.ReleaseStatic|x64.ActiveCfg = Release|x64
624624
{68808357-902B-406C-8C19-E8E26A69DE8A}.ReleaseStatic|x86.ActiveCfg = Release|x86
625-
{68808357-902B-406C-8C19-E8E26A69DE8A}.TestRelease|ARM64.ActiveCfg = Release|ARM64
625+
{68808357-902B-406C-8C19-E8E26A69DE8A}.TestRelease|ARM64.ActiveCfg = Release|x64
626626
{68808357-902B-406C-8C19-E8E26A69DE8A}.TestRelease|x64.ActiveCfg = Release|x64
627627
{68808357-902B-406C-8C19-E8E26A69DE8A}.TestRelease|x86.ActiveCfg = Release|x86
628628
{2046B5AF-666D-4CE8-8D3E-C32C57908A56}.Debug|ARM64.ActiveCfg = Debug|ARM64

src/AppInstallerCLICore/AppInstallerCLICore.vcxproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@
176176
<PrecompiledHeaderOutputFile>$(IntDir)pch.pch</PrecompiledHeaderOutputFile>
177177
<PreprocessorDefinitions>_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
178178
<WarningLevel>Level4</WarningLevel>
179+
<DisableSpecificWarnings>5321;%(DisableSpecificWarnings)</DisableSpecificWarnings>
179180
<AdditionalOptions>%(AdditionalOptions) /permissive- /bigobj /D _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING</AdditionalOptions>
180181
</ClCompile>
181182
</ItemDefinitionGroup>
@@ -498,4 +499,4 @@
498499
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorTextNuget)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.props'))" />
499500
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorTextNuget)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.targets'))" />
500501
</Target>
501-
</Project>
502+
</Project>

src/AppInstallerCLITests/AppInstallerCLITests.vcxproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@
116116
<PrecompiledHeaderOutputFile>$(IntDir)pch.pch</PrecompiledHeaderOutputFile>
117117
<PreprocessorDefinitions>_CONSOLE;WIN32_LEAN_AND_MEAN;WINRT_LEAN_AND_MEAN;%(PreprocessorDefinitions)</PreprocessorDefinitions>
118118
<WarningLevel>Level4</WarningLevel>
119+
<DisableSpecificWarnings>5321;%(DisableSpecificWarnings)</DisableSpecificWarnings>
119120
<AdditionalOptions>%(AdditionalOptions) /permissive- /bigobj /D _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING</AdditionalOptions>
120121
</ClCompile>
121122
</ItemDefinitionGroup>
@@ -1054,4 +1055,4 @@
10541055
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.props'))" />
10551056
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.230706.1\build\native\Microsoft.Windows.CppWinRT.targets'))" />
10561057
</Target>
1057-
</Project>
1058+
</Project>

src/AppInstallerCLITests/Dependencies.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ TEST_CASE("DependencyGraph_BFirst", "[dependencyGraph][dependencies]")
3838
DependencyList rootDependencies;
3939
std::for_each(installers.begin(), installers.end(), [&](ManifestInstaller installer) { rootDependencies.Add(installer.Dependencies); });
4040

41-
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency node)
41+
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency)
4242
{
4343
DependencyList dependencyList;
4444
auto dependencyManifest = CreateFakeManifestWithDependencies(manifest.Id);
@@ -72,7 +72,7 @@ TEST_CASE("DependencyGraph_InStackNoLoop", "[dependencyGraph][dependencies]")
7272
DependencyList rootDependencies;
7373
std::for_each(installers.begin(), installers.end(), [&](ManifestInstaller installer) { rootDependencies.Add(installer.Dependencies); });
7474

75-
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency node)
75+
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency)
7676
{
7777
DependencyList dependencyList;
7878
auto dependencyManifest = CreateFakeManifestWithDependencies(manifest.Id);
@@ -106,7 +106,7 @@ TEST_CASE("DependencyGraph_EasyToSeeLoop", "[dependencyGraph][dependencies]")
106106
DependencyList rootDependencies;
107107
std::for_each(installers.begin(), installers.end(), [&](ManifestInstaller installer) { rootDependencies.Add(installer.Dependencies); });
108108

109-
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency node) {
109+
DependencyGraph graph(rootAsDependency, rootDependencies, [&](Dependency) {
110110
DependencyList dependencyList;
111111
auto dependencyManifest = CreateFakeManifestWithDependencies(manifest.Id);
112112

src/AppInstallerCLITests/TestRestRequestHandler.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
std::shared_ptr<TestRestRequestHandler> GetTestRestRequestHandler(
1010
const web::http::status_code statusCode, const utility::string_t& sampleResponseString, const utility::string_t& mimeType)
1111
{
12-
return std::make_shared<TestRestRequestHandler>([statusCode, sampleResponseString, mimeType](web::http::http_request request) ->
12+
return std::make_shared<TestRestRequestHandler>([statusCode, sampleResponseString, mimeType](web::http::http_request) ->
1313
pplx::task<web::http::http_response>
1414
{
1515
web::http::http_response response;
@@ -68,4 +68,4 @@ std::shared_ptr<TestRestRequestHandler> GetHeaderVerificationHandler(
6868
response.set_status_code(statusCode);
6969
return pplx::task_from_result(response);
7070
});
71-
}
71+
}

src/AppInstallerCommonCore/Authentication/WebAccountManagerAuthenticator.cpp

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,15 @@ namespace AppInstaller::Authentication
219219
AICLI_LOG(Core, Error, << "CreateTokenRequest returned empty request");
220220
return {};
221221
}
222-
223-
return HandleGetTokenResult(WebAuthenticationCoreManager::GetTokenSilentlyAsync(request).get());
222+
223+
if (webAccount)
224+
{
225+
return HandleGetTokenResult(WebAuthenticationCoreManager::GetTokenSilentlyAsync(request, webAccount).get());
226+
}
227+
else
228+
{
229+
return HandleGetTokenResult(WebAuthenticationCoreManager::GetTokenSilentlyAsync(request).get());
230+
}
224231
}
225232

226233
AuthenticationResult WebAccountManagerAuthenticator::HandleGetTokenResult(WebTokenRequestResult requestResult)

src/Microsoft.Management.Deployment/PackageManager.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -898,8 +898,7 @@ namespace winrt::Microsoft::Management::Deployment::implementation
898898

899899
std::unique_ptr<Execution::OrchestratorQueueItem> CreateQueueItemForRepair(
900900
std::unique_ptr<::AppInstaller::CLI::Execution::COMContext> comContext,
901-
winrt::Microsoft::Management::Deployment::CatalogPackage package,
902-
winrt::Microsoft::Management::Deployment::RepairOptions options)
901+
winrt::Microsoft::Management::Deployment::CatalogPackage package)
903902
{
904903
// Add installed version
905904
AddInstalledVersionToContext(package.InstalledVersion(), comContext.get());
@@ -956,7 +955,7 @@ namespace winrt::Microsoft::Management::Deployment::implementation
956955
}
957956
else if constexpr (std::is_same_v<TOptions, winrt::Microsoft::Management::Deployment::RepairOptions>)
958957
{
959-
queueItem = CreateQueueItemForRepair(std::move(comContext), package, options);
958+
queueItem = CreateQueueItemForRepair(std::move(comContext), package);
960959
}
961960

962961
Execution::ContextOrchestrator::Instance().EnqueueAndRunItem(queueItem);

src/WinGetYamlFuzzing/OneFuzzConfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"Org": "microsoft",
2525
"Project": "OS",
2626
"AssignedTo": "[email protected]",
27-
"AreaPath": "OS\\Windows Client and Services\\WinPD\\DFX-Developer Fundamentals and Experiences\\InstaDev",
27+
"AreaPath": "OS\\Windows Client and Services\\WinPD\\DFX-Developer Fundamentals and Experiences\\DEFT\\InstaDev",
2828
"IterationPath": "OS"
2929
},
3030
"codeCoverage": {

0 commit comments

Comments
 (0)