Skip to content

Commit

Permalink
Set addrsize correctly before calling accept()
Browse files Browse the repository at this point in the history
  • Loading branch information
salcock committed Nov 12, 2024
1 parent 544ddba commit 468a11b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/format_ndag.c
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ static int accept_ndagtcp_connection(libtrace_t *libtrace, char *ipstr,
consock = 0;
continue;
}

addrsize = sizeof(struct sockaddr_storage);
consock = accept(sock, (struct sockaddr *)&sa, &addrsize);
if (consock < 0) {
fprintf(stderr,
Expand Down

0 comments on commit 468a11b

Please sign in to comment.