From 0830d06cd64556bc2b51aec47616ca1f3b28512f Mon Sep 17 00:00:00 2001 From: Wu Zheng Date: Mon, 2 Jul 2012 13:21:05 +0800 Subject: [PATCH] tethering: Fix incorrect index value for private network In __connman_private_network_request, pn->fd is used as the index value and passed to __connman_ippool_create, which is not correct. It result in the private network is block used externally. --- src/tethering.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tethering.c b/src/tethering.c index c67f200..265408b 100644 --- a/src/tethering.c +++ b/src/tethering.c @@ -421,7 +421,7 @@ int __connman_private_network_request(DBusMessage *msg, const char *owner) pn->fd = fd; pn->interface = iface; pn->index = index; - pn->pool = __connman_ippool_create(pn->fd, 1, 1, ippool_disconnect, pn); + pn->pool = __connman_ippool_create(pn->index, 1, 1, ippool_disconnect, pn); if (pn->pool == NULL) { errno = -ENOMEM; goto error; -- 2.7.4