Skip to content

Commit f892427

Browse files
bretambrosegraebm
andauthored
Update host resolver creation to new interface (aws#202)
Co-authored-by: Michael Graeb <[email protected]>
1 parent 7899418 commit f892427

File tree

8 files changed

+13
-8
lines changed

8 files changed

+13
-8
lines changed

cmake/AwsCheckHeadersCxx.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ function(aws_check_headers_cxx target)
1919
if (NOT CMAKE_VERSION VERSION_LESS "3.8")
2020
aws_check_headers_cxx_internal(${target} 17 ${ARGN})
2121

22-
if (NOT CMAKE_VERSION VERSION_LESS "3.12")
22+
if (NOT CMAKE_VERSION VERSION_LESS "3.12" AND NOT MSVC)
2323
aws_check_headers_cxx_internal(${target} 20 ${ARGN})
2424
endif ()
2525
endif ()

crt/aws-c-common

Submodule aws-c-common updated 275 files

source/io/HostResolver.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,12 @@ namespace Aws
2525
{
2626
AWS_ZERO_STRUCT(m_config);
2727

28-
m_resolver = aws_host_resolver_new_default(allocator, maxHosts, elGroup.GetUnderlyingHandle(), NULL);
28+
struct aws_host_resolver_default_options resolver_options;
29+
AWS_ZERO_STRUCT(resolver_options);
30+
resolver_options.max_entries = maxHosts;
31+
resolver_options.el_group = elGroup.GetUnderlyingHandle();
32+
33+
m_resolver = aws_host_resolver_new_default(allocator, &resolver_options);
2934
if (m_resolver != nullptr)
3035
{
3136
m_initialized = true;

0 commit comments

Comments
 (0)