Don't leave fd undefined.

When gcc isn't optimizing well, it might not realize that it's not
possible to return fd without initializing it, and then the build fails
due to -Werror.
release
Tim Newsome 2017-06-06 11:36:49 -07:00 committed by Palmer Dabbelt
parent 51ab5a0c8b
commit 83afb93004
1 changed files with 1 additions and 1 deletions

View File

@ -131,7 +131,7 @@ static int remote_bitbang_init_tcp(void)
{
struct addrinfo hints = { .ai_family = AF_UNSPEC, .ai_socktype = SOCK_STREAM };
struct addrinfo *result, *rp;
int fd;
int fd = 0;
LOG_INFO("Connecting to %s:%s",
remote_bitbang_host ? remote_bitbang_host : "localhost",