summaryrefslogtreecommitdiff
path: root/include/session.h
diff options
context:
space:
mode:
authorDaniel Wagner <daniel.wagner@bmw-carit.de>2012-09-19 13:37:14 +0200
committerDaniel Wagner <daniel.wagner@bmw-carit.de>2012-09-27 10:28:28 +0200
commita5e3f919ed56b1aba3893abc780039ad32debb90 (patch)
tree68e32af56ab7b129d6fcfc7c2cf234fa126cd4b5 /include/session.h
parentdc7095e240c3a4ca50805e7f2d2249e6cecd4e78 (diff)
downloadconnman-a5e3f919ed56b1aba3893abc780039ad32debb90.tar.gz
connman-a5e3f919ed56b1aba3893abc780039ad32debb90.tar.bz2
connman-a5e3f919ed56b1aba3893abc780039ad32debb90.zip
session: Use session pointer instead of string id
Instead of passing in some string to identify we can use the connman_session pointer. This allows us to keep the way sessions are identfied away from the core, e.g. using the D-Bus owner id or something else.
Diffstat (limited to 'include/session.h')
-rw-r--r--include/session.h13
1 files changed, 6 insertions, 7 deletions
diff --git a/include/session.h b/include/session.h
index 2871d509..3c6e6ff0 100644
--- a/include/session.h
+++ b/include/session.h
@@ -34,22 +34,21 @@ extern "C" {
struct connman_session;
-/*
- * The session are identified through the pid is only a temporary solution
- */
struct connman_session_policy {
const char *name;
int priority;
- int (*get_bool) (const char *id, const char *key, connman_bool_t *val);
- int (*get_string) (const char *id, const char *key, char **val);
+ int (*get_bool) (struct connman_session *session,
+ const char *key, connman_bool_t *val);
+ int (*get_string) (struct connman_session *session,
+ const char *key, char **val);
};
int connman_session_policy_register(struct connman_session_policy *config);
void connman_session_policy_unregister(struct connman_session_policy *config);
-int connman_session_update_bool(const char *id, const char *key,
+int connman_session_update_bool(struct connman_session *session, const char *key,
connman_bool_t val);
-int connman_session_update_string(const char *id, const char *key,
+int connman_session_update_string(struct connman_session *session, const char *key,
const char *val);
#ifdef __cplusplus