mirror of
https://dev.iopsys.eu/bbf/icwmp.git
synced 2026-01-28 01:27:16 +01:00
Fix use IPv4 address only when v6 is disabled
This commit is contained in:
parent
195fcb32c2
commit
cd511ce6a5
1 changed files with 2 additions and 0 deletions
2
http.c
2
http.c
|
|
@ -98,6 +98,8 @@ int http_client_init(struct cwmp *cwmp)
|
|||
int tmp = inet_pton(AF_INET, ip, buf);
|
||||
|
||||
cwmp_uci_set_value("cwmp", "acs", "ip_version", (tmp == 1) ? "4" : "6");
|
||||
} else {
|
||||
curl_easy_setopt(curl, CURLOPT_IPRESOLVE, CURL_IPRESOLVE_V4);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue