Fix compile error and warning with gcc
This commit is contained in:
parent
f0d2c9f94b
commit
22a89ff7a6
|
@ -303,7 +303,7 @@ int Client::connect() {
|
|||
return -1;
|
||||
}
|
||||
} else {
|
||||
addrinfo *addr;
|
||||
addrinfo *addr = nullptr;
|
||||
while (next_addr) {
|
||||
addr = next_addr;
|
||||
next_addr = next_addr->ai_next;
|
||||
|
@ -317,6 +317,8 @@ int Client::connect() {
|
|||
return -1;
|
||||
}
|
||||
|
||||
assert(addr);
|
||||
|
||||
current_addr = addr;
|
||||
}
|
||||
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
|
||||
#include "nghttp2_config.h"
|
||||
|
||||
#include <cstring>
|
||||
#include <memory>
|
||||
#include <array>
|
||||
#include <functional>
|
||||
|
|
Loading…
Reference in New Issue