Commit a4223aac authored by Uli Schlachter's avatar Uli Schlachter Committed by Max Kellermann

ServerSocket: Initialize length variable

parent 2bb751d9
......@@ -304,7 +304,7 @@ ServerSocket::AddFD(int fd, GError **error_r)
assert(fd >= 0);
struct sockaddr_storage address;
socklen_t address_length;
socklen_t address_length = sizeof(address);
if (getsockname(fd, (struct sockaddr *)&address,
&address_length) < 0) {
SetSocketError(error_r);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment