diff options
Diffstat (limited to 'src/shared/bus-polkit.c')
-rw-r--r-- | src/shared/bus-polkit.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/shared/bus-polkit.c b/src/shared/bus-polkit.c index 14122e0876..bbe04bea37 100644 --- a/src/shared/bus-polkit.c +++ b/src/shared/bus-polkit.c @@ -408,8 +408,11 @@ int bus_verify_polkit_async( return -EACCES; } -void bus_verify_polkit_async_registry_free(Hashmap *registry) { +Hashmap *bus_verify_polkit_async_registry_free(Hashmap *registry) { #if ENABLE_POLKIT - hashmap_free_with_destructor(registry, async_polkit_query_free); + return hashmap_free_with_destructor(registry, async_polkit_query_free); +#else + assert(hashmap_isempty(registry)); + return hashmap_free(registry); #endif } |