diff options
Diffstat (limited to 'src/aul_screen_connector.c')
-rw-r--r-- | src/aul_screen_connector.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/aul_screen_connector.c b/src/aul_screen_connector.c index d7ba58ff..e6a9a515 100644 --- a/src/aul_screen_connector.c +++ b/src/aul_screen_connector.c @@ -171,6 +171,8 @@ static int __screen_viewer_fini(void) static int __screen_viewer_init(void) { int ret; + char endpoint[128]; + pid_t pid = getpid(); if (screen_viewer_initialized) return 0; @@ -181,7 +183,8 @@ static int __screen_viewer_init(void) return -1; } - aul_app_com_create("app_screen_added", NULL, __app_screen_added, + snprintf(endpoint, sizeof(endpoint), "app_screen_added:%d", pid); + aul_app_com_create(endpoint, NULL, __app_screen_added, NULL, &added_conn); if (added_conn == NULL) { _E("Failed to create app com - watch_app_added"); @@ -189,7 +192,8 @@ static int __screen_viewer_init(void) return -1; } - aul_app_com_create("app_screen_removed", NULL, __app_screen_removed, + snprintf(endpoint, sizeof(endpoint), "app_screen_removed:%d", pid); + aul_app_com_create(endpoint, NULL, __app_screen_removed, NULL, &removed_conn); if (removed_conn == NULL) { _E("Failed to create app com - watch_app_removed"); |