#include "bus-error.h"
#include "logind-session.h"
-static unsigned devt_hash_func(const void *p) {
+static unsigned long devt_hash_func(const void *p, const uint8_t hash_key[HASH_KEY_SIZE]) {
uint64_t u = *(const dev_t*)p;
- return uint64_hash_func(&u);
+ return uint64_hash_func(&u, hash_key);
}
static int devt_compare_func(const void *_a, const void *_b) {
return NULL;
}
- s->id = path_get_file_name(s->state_file);
+ s->id = basename(s->state_file);
if (hashmap_put(m->sessions, s->id, s) < 0) {
hashmap_free(s->devices);
SessionState session_get_state(Session *s) {
assert(s);
- if (s->closing)
- return SESSION_CLOSING;
-
if (s->scope_job)
return SESSION_OPENING;