Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
ca9ceddd
Commit
ca9ceddd
authored
Jan 05, 2013
by
Francois Gouget
Committed by
Alexandre Julliard
Jan 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
netstat: Fix compilation on systems that don't support nameless unions.
parent
f963f939
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
netstat.c
programs/netstat/netstat.c
+5
-4
No files found.
programs/netstat/netstat.c
View file @
ca9ceddd
...
...
@@ -16,6 +16,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#define NONAMELESSUNION
#include "netstat.h"
#include <winsock2.h>
#include <iphlpapi.h>
...
...
@@ -178,9 +179,9 @@ static void NETSTAT_tcp_table(void)
for
(
i
=
0
;
i
<
table
->
dwNumEntries
;
i
++
)
{
if
((
table
->
table
[
i
].
dwState
==
MIB_TCP_STATE_CLOSE_WAIT
)
||
(
table
->
table
[
i
].
dwState
==
MIB_TCP_STATE_ESTAB
)
||
(
table
->
table
[
i
].
dwState
==
MIB_TCP_STATE_TIME_WAIT
))
if
((
table
->
table
[
i
].
u
.
dwState
==
MIB_TCP_STATE_CLOSE_WAIT
)
||
(
table
->
table
[
i
].
u
.
dwState
==
MIB_TCP_STATE_ESTAB
)
||
(
table
->
table
[
i
].
u
.
dwState
==
MIB_TCP_STATE_TIME_WAIT
))
{
NETSTAT_host_name
(
table
->
table
[
i
].
dwLocalAddr
,
HostIp
);
NETSTAT_port_name
(
table
->
table
[
i
].
dwLocalPort
,
HostPort
);
...
...
@@ -189,7 +190,7 @@ static void NETSTAT_tcp_table(void)
sprintfW
(
Host
,
fmtcolon
,
HostIp
,
HostPort
);
sprintfW
(
Remote
,
fmtcolon
,
RemoteIp
,
RemotePort
);
NETSTAT_wprintf
(
fmttcpout
,
tcpW
,
Host
,
Remote
,
NETSTAT_load_message
(
table
->
table
[
i
].
dwState
));
NETSTAT_wprintf
(
fmttcpout
,
tcpW
,
Host
,
Remote
,
NETSTAT_load_message
(
table
->
table
[
i
].
u
.
dwState
));
}
}
HeapFree
(
GetProcessHeap
(),
0
,
table
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment