Skip to content

Commit

Permalink
Small corrections to if_indextoname resolution on win32, compiles clean
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1855864 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
wrowe committed Mar 19, 2019
1 parent dfee56a commit e304d7e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/arch/win32/apr_arch_misc.h
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ APR_DECLARE_LATE_DLL_FUNC(DLL_IPHLPAPI, NET_IFINDEX, WINAPI, if_nametoindex, 0,
#undef if_indextoname
#endif
APR_DECLARE_LATE_DLL_FUNC(DLL_IPHLPAPI, PCHAR, NETIOAPI_API_, if_indextoname, 0, (
NET_IFINDEX InterfaceIndex
NET_IFINDEX InterfaceIndex,
PCHAR InterfaceName),
(InterfaceIndex, InterfaceName));
#define if_indextoname apr_winapi_if_indextoname
Expand Down
4 changes: 2 additions & 2 deletions network_io/unix/sockaddr.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#endif

#if defined(HAVE_IF_INDEXTONAME) && defined(_MSC_VER)
#include <Iphlpapi.h>
#include "arch/win32/apr_arch_misc.h"
#endif

#define APR_WANT_STRFUNC
Expand Down Expand Up @@ -1251,7 +1251,7 @@ APR_DECLARE(apr_status_t) apr_sockaddr_zone_set(apr_sockaddr_t *sa,
return APR_EGENERAL;
}

sa->sa.sin6.sin6_scope_id = i;
sa->sa.sin6.sin6_scope_id = (unsigned int) i;
return APR_SUCCESS;
}
#endif
Expand Down

0 comments on commit e304d7e

Please sign in to comment.