]> git.ipfire.org Git - thirdparty/openvpn.git/commitdiff
Skip error about ioctl(SIOCGIFCONF) failed on Android
authorArne Schwabe <arne@rfc2549.org>
Fri, 5 Oct 2018 13:16:32 +0000 (15:16 +0200)
committerGert Doering <gert@greenie.muc.de>
Fri, 5 Oct 2018 14:45:52 +0000 (16:45 +0200)
Patch: V2 Do not use C99 style comments

Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20181005131632.32515-1-arne@rfc2549.org>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg17565.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/route.c

index 8a3e8b4449b0d179b62f1615ea7435ca3cf8721a..d97e8dbac30b25c9eea7dee1ecd447852d9361ee 100644 (file)
@@ -3243,6 +3243,12 @@ get_default_gateway(struct route_gateway_info *rgi)
     rgi->gateway.addr = 127 << 24 | 'd' << 16 | 'g' << 8 | 'w';
     rgi->flags |= RGI_ADDR_DEFINED;
     strcpy(best_name, "android-gw");
+
+    /*
+     * Skip scanning/fetching interface from loopback interface
+     * It always fails and "ioctl(SIOCGIFCONF) failed" confuses users
+     */
+    goto done;
 #endif /* ifndef TARGET_ANDROID */
 
     /* scan adapter list */