switching to host / network ordering swapping

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26859 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2004-04-18 16:37:16 +00:00
parent 3b8d819f30
commit 377f6397ac
2 changed files with 10 additions and 10 deletions

View File

@@ -211,10 +211,10 @@ wxString wxIPV4address::IPAddress() const
unsigned long raw = GAddress_INET_GetHostAddress(m_address);
return wxString::Format(
_T("%u.%u.%u.%u"),
(unsigned char)(raw & 0xff),
(unsigned char)((raw>>8) & 0xff),
(unsigned char)((raw>>24) & 0xff),
(unsigned char)((raw>>16) & 0xff),
(unsigned char)((raw>>24) & 0xff)
(unsigned char)((raw>>8) & 0xff),
(unsigned char)(raw & 0xff)
);
}
@@ -288,10 +288,10 @@ wxString wxIPV6address::IPAddress() const
unsigned long raw = GAddress_INET_GetHostAddress(m_address);
return wxString::Format(
_T("%u.%u.%u.%u"),
(unsigned char)(raw & 0xff),
(unsigned char)((raw>>8) & 0xff),
(unsigned char)((raw>>24) & 0xff),
(unsigned char)((raw>>16) & 0xff),
(unsigned char)((raw>>24) & 0xff)
(unsigned char)((raw>>8) & 0xff),
(unsigned char)(raw & 0xff)
);
}