From 449f2e3c3cb9e8d707c1c08172f848ce52d62dd4 Mon Sep 17 00:00:00 2001 From: Martin Xu Date: Mon, 12 Apr 2010 14:35:03 +0800 Subject: [PATCH] Add __connman_ipconfig_set_index() helper --- src/connman.h | 1 + src/ipconfig.c | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/src/connman.h b/src/connman.h index d2de80a..16ded2d 100644 --- a/src/connman.h +++ b/src/connman.h @@ -215,6 +215,7 @@ void __connman_ipconfig_foreach(void (*function) (int index, void *user_data), unsigned short __connman_ipconfig_get_type(int index); unsigned int __connman_ipconfig_get_flags(int index); const char *__connman_ipconfig_get_gateway(int index); +void __connman_ipconfig_set_index(struct connman_ipconfig *ipconfig, int index); int __connman_ipconfig_enable(struct connman_ipconfig *ipconfig); int __connman_ipconfig_disable(struct connman_ipconfig *ipconfig); diff --git a/src/ipconfig.c b/src/ipconfig.c index 9529846..4e4e095 100644 --- a/src/ipconfig.c +++ b/src/ipconfig.c @@ -715,6 +715,11 @@ const char *__connman_ipconfig_get_gateway(int index) return ipdevice->gateway; } +void __connman_ipconfig_set_index(struct connman_ipconfig *ipconfig, int index) +{ + ipconfig->index = index; +} + /** * connman_ipconfig_create: * -- 2.7.4