Hi all,
I'm trying to implement the inet_ntop function in Windows, and I found
the code from http://www.mail-archive.com/us...@ipv6.org/msg02107.html
I'm using Visual Studio .NET 2003, and according to the msdn article
for getnameinfo(), I need to include the Ws2tcpip.h file and also
include the Wspiapi.h file. So in my header file, I have
#include <Ws2tcpip.h>
#include <Wspiapi.h>
#include <string.h>
and the function definition is in a .c file. Ws232.lib is also
specified in my Project properties -> Configuration Properties ->
Linker -> Input -> Additional Dependencies.
However, I have the following errors (several instances of each error
shown below, and several other similar ones) and they all point to the
Ws2tcpip.h file.
error C2039: 'Byte' : is not a member of 'in6_addr::__unnamed'
error C2039: 'sin6_flowinfo' : is not a member of 'sockaddr_in6'
error C2039: 'sin6_port' : is not a member of 'sockaddr_in6'
error C2039: 'sin6_scope_id' : is not a member of 'sockaddr_in6'
error C2039: 'Word' : is not a member of 'in6_addr::__unnamed'
error C2065: 'AF_INET6' : undeclared identifier
error C2079: 'ip_mreq::imr_interface' uses undefined struct 'in_addr'
error C2079: 'ip_msfilter::imr_interface' uses undefined struct
'in_addr'
error C2079: 'sockaddr_gen::Address' uses undefined struct 'sockaddr'
error C2079: 'sockaddr_gen::AddressIn' uses undefined struct
'sockaddr_in'
error C2371: 'FAR' : redefinition; different basic types
error C2501: 'in6_addr::__unnamed::Byte' : missing storage-class or
type specifiers
error C3861: 'AF_INET6': identifier not found, even with argument-
dependent lookup
error C3861: 'memcmp': identifier not found, even with argument-
dependent lookup
error C3861: 'memset': identifier not found, even with argument-
dependent lookup
I've tried including <Windows.h> and switching the order of
<Ws2tcpip.h> and <Wspiapi.h>, but I still get the errors. Why is this
so?
Thank you.
Regards,
Rayne
|
|
0
|
|
|
|
Reply
|
lancer6238682 (96)
|
12/8/2009 3:57:46 AM |
|
On 8 d=E9c, 04:57, Rayne <lancer6...@yahoo.com> wrote:
> I'm trying to implement the inet_ntop function in Windows,
There is :
RtlIpv4AddressToStringEx()
RtlIpv6AddressToStringEx()
(MSDN says Vista for minimum OS, but it's wrong, it's on XP also...)
(or WSAAddressToString)
|
|
0
|
|
|
|
Reply
|
Christian
|
12/8/2009 8:10:04 AM
|
|
On Dec 8, 4:10 pm, Christian ASTOR <casto...@club-internet.fr> wrote:
> On 8 d=E9c, 04:57, Rayne <lancer6...@yahoo.com> wrote:
>
> > I'm trying to implement the inet_ntop function in Windows,
>
> There is :
> RtlIpv4AddressToStringEx()
> RtlIpv6AddressToStringEx()
> (MSDN says Vista for minimum OS, but it's wrong, it's on XP also...)
>
> (or WSAAddressToString)
Can I use WSAAddressToString on Windows 2000?
|
|
0
|
|
|
|
Reply
|
Rayne
|
12/8/2009 9:01:25 AM
|
|
Rayne a =E9crit :
> Can I use WSAAddressToString on Windows 2000?
See MSDN :
Minimum supported client Windows 2000 Professional
|
|
0
|
|
|
|
Reply
|
marc
|
12/8/2009 11:45:00 AM
|
|
|
3 Replies
701 Views
(page loaded in 0.078 seconds)
Similiar Articles: inet_ntop in windows - comp.os.ms-windows.programmer.win32 ...On Dec 8, 4:10 pm, Christian ASTOR <casto...@club-internet.fr> wrote: > On 8 d=E9c, 04:57, Rayne <lancer6...@yahoo.com> wrote: > > > I'm trying to implement the inet ... SNTP IPv6 address support on Windows - comp.protocols.time.ntp ...inet_ntop in windows - comp.os.ms-windows.programmer.win32 ... SNTP IPv6 address support on Windows - comp.protocols.time.ntp ... inet_ntop in windows - comp.os.ms-windows ... ntpd IPv6 support on Windows? - comp.protocols.time.ntpI am running Meinberg's Win32 binaries on Windows Server 2003: ntpd 4.2.4p5 ... inet_ntop in windows - comp.os.ms-windows.programmer.win32 ..... the code from http://www ... getaddrinfo() bug ? - comp.unix.solarisSNTP IPv6 address support on Windows - comp.protocols.time.ntp ..... time.ntp ... inet_ntop in windows - comp.os.ms-windows.programmer.win32 ... getaddrinfo ... Answer : inet_ntop in windows - GNT : your source for software ..."Rayne" ha scritto nel messaggio news: I actually left out the inet_pton function, because I only want inet_ntop. Did you only #include <Ws2tcpip.h>? inet_ntop in windows, help, FAQ, forums, question, answer, advice ...Rayne wrote: On Dec 8, 7:20 pm, "Giovanni Dicanio" wrote: "Rayne" ha scritto nel messaggionews: I tried the code on a completely new project, and still get the errors 7/25/2012 3:05:39 PM
|