mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-02 22:54:52 +00:00
tests/netinet: push variable 'sin' into function scope
This should fix build with GCC 13.
Fixes: 861274c9f8
This commit is contained in:
parent
c1f6704bf8
commit
70f5c6e34f
|
@ -33,17 +33,15 @@
|
|||
|
||||
#include <atf-c.h>
|
||||
|
||||
static struct sockaddr_in sin = {
|
||||
.sin_family = AF_INET,
|
||||
.sin_len = sizeof(sin),
|
||||
};
|
||||
|
||||
static const char buf[] = "hello";
|
||||
static char repl[sizeof(buf)];
|
||||
|
||||
ATF_TC_WITHOUT_HEAD(tcp_implied_connect);
|
||||
ATF_TC_BODY(tcp_implied_connect, tc)
|
||||
{
|
||||
struct sockaddr_in sin = {
|
||||
.sin_family = AF_INET,
|
||||
.sin_len = sizeof(sin),
|
||||
};
|
||||
const char buf[] = "hello";
|
||||
char repl[sizeof(buf)];
|
||||
socklen_t len;
|
||||
int s, c, a;
|
||||
|
||||
|
|
Loading…
Reference in a new issue