From ea5b1fb70fa718bd68b63de75f12881fab9f9c21 Mon Sep 17 00:00:00 2001 From: Daniel Wagner Date: Mon, 11 Oct 2010 13:58:02 +0200 Subject: Open stats file late and close them early Instead of opening stats file when a service is created, defer it to the point where either __connman_ipconfig_enable or __connman_ipconfig_disable is called. --- src/stats.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/stats.c') diff --git a/src/stats.c b/src/stats.c index f646bac9..0ad8ae22 100644 --- a/src/stats.c +++ b/src/stats.c @@ -349,6 +349,8 @@ int __connman_stats_service_register(struct connman_service *service) return err; handle = g_hash_table_lookup(stats_hash, service); + } else { + return -EALREADY; } err = stats_open(service, handle); -- cgit v1.2.3