+static int user_start_slice(User *u) {
+ // char *job;
+ int r;
+
+ assert(u);
+
+ if (!u->slice) {
+ _cleanup_bus_error_free_ sd_bus_error error = SD_BUS_ERROR_NULL;
+ char lu[DECIMAL_STR_MAX(uid_t) + 1], *slice;
+ sprintf(lu, UID_FMT, u->uid);
+
+ r = slice_build_subslice("user", lu, &slice);
+ if (r < 0)
+ return r;
+
+/// elogind : Do not try to use dbus to ask systemd
+#if 0
+ r = manager_start_unit(u->manager, slice, &error, &job);
+ if (r < 0) {
+ log_error("Failed to start user slice: %s", bus_error_message(&error, r));
+ free(slice);
+ } else {
+#endif // 0
+ u->slice = slice;
+
+/// elogind does not support slice jobs
+#if 0
+ free(u->slice_job);
+ u->slice_job = job;
+ }
+#endif // 0
+ }
+
+ if (u->slice)
+ hashmap_put(u->manager->user_units, u->slice, u);
+
+ return 0;
+}
+
+static int user_start_service(User *u) {
+ _cleanup_bus_error_free_ sd_bus_error error = SD_BUS_ERROR_NULL;
+ // char *job;
+ int r;
+
+ assert(u);
+
+ if (!u->service) {
+ char lu[DECIMAL_STR_MAX(uid_t) + 1], *service;
+ sprintf(lu, UID_FMT, u->uid);
+
+ r = unit_name_build("user", lu, ".service", &service);
+ if (r < 0)
+ return log_error_errno(r, "Failed to build service name: %m");
+
+/// elogind : Do not try to use dbus to ask systemd
+#if 0
+ r = manager_start_unit(u->manager, service, &error, &job);
+#endif // 0
+ if (r < 0) {
+ log_error("Failed to start user service: %s", bus_error_message(&error, r));
+ free(service);
+ } else {
+ u->service = service;
+
+/// elogind does not support service jobs
+#if 0
+ free(u->service_job);
+ u->service_job = job;
+#endif // 0
+ }
+ }
+
+ if (u->service)
+ hashmap_put(u->manager->user_units, u->service, u);
+
+ return 0;
+}
+