From 897f9876936ce0a3f0ae6798725e1162a3e62ff9 Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Wed, 31 Dec 2008 09:08:50 +0100 Subject: [PATCH] Set interface name for connection objects --- plugins/Makefile.am | 2 +- plugins/ipv4.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/plugins/Makefile.am b/plugins/Makefile.am index efcb5b7..e663e14 100644 --- a/plugins/Makefile.am +++ b/plugins/Makefile.am @@ -27,7 +27,7 @@ dhclient_la_SOURCES = dhclient.c inet.h inet.c dhclient_la_CFLAGS = @GLIB_CFLAGS@ @GDBUS_CFLAGS@ -DDHCLIENT=\"@DHCLIENT@\" \ -DSTATEDIR=\""$(statedir)"\" -DSCRIPTDIR=\""$(scriptdir)"\" -ipv4_la_SOURCES = ipv4.c +ipv4_la_SOURCES = ipv4.c inet.h inet.c dnsproxy_la_SOURCES = dnsproxy.c diff --git a/plugins/ipv4.c b/plugins/ipv4.c index 33c73a4..5e19cbb 100644 --- a/plugins/ipv4.c +++ b/plugins/ipv4.c @@ -397,8 +397,9 @@ static int ipv4_probe(struct connman_element *element) connection = connman_element_create(NULL); - connection->type = CONNMAN_ELEMENT_TYPE_CONNECTION; - connection->index = element->index; + connection->type = CONNMAN_ELEMENT_TYPE_CONNECTION; + connection->index = element->index; + connection->devname = inet_index2name(element->index); if (connman_element_register(connection, element) < 0) connman_element_unref(connection); -- 1.7.9.5