mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-08-09 09:51:49 +08:00
tests: initialize worker_st using = {0}
Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>
This commit is contained in:
+1
-3
@@ -73,12 +73,10 @@ void writer(int fd)
|
||||
|
||||
void receiver(int fd)
|
||||
{
|
||||
worker_st ws;
|
||||
worker_st ws = { 0 };
|
||||
unsigned char buf[MAX_SIZE * 3];
|
||||
int ret;
|
||||
unsigned int i;
|
||||
|
||||
memset(&ws, 0, sizeof(ws));
|
||||
ws.conn_fd = fd;
|
||||
|
||||
for (i = 0; i < ITERATIONS; i++) {
|
||||
|
||||
@@ -39,12 +39,10 @@ static unsigned int try(const char *src, unsigned int src_port, const char *dst,
|
||||
unsigned int dst_port)
|
||||
{
|
||||
char str[256];
|
||||
struct worker_st ws;
|
||||
struct worker_st ws = { 0 };
|
||||
unsigned int ipv6 = 0;
|
||||
int ret;
|
||||
|
||||
memset(&ws, 0, sizeof(ws));
|
||||
|
||||
if (strchr(src, ':') != NULL) {
|
||||
/* ipv6 */
|
||||
snprintf(str, sizeof(str), "TCP6 %s %s %u %u\r\n", src, dst,
|
||||
|
||||
Reference in New Issue
Block a user