mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-09-05 21:21:49 +00:00
Fix segv introduced by 2fd069b18e
n->path is pointing to the value now, we set s = NULL above.
This commit is contained in:
@@ -1379,7 +1379,7 @@ static struct node *bus_node_allocate(sd_bus *bus, const char *path) {
|
||||
n->path = s;
|
||||
s = NULL; /* do not free */
|
||||
|
||||
r = hashmap_put(bus->nodes, s, n);
|
||||
r = hashmap_put(bus->nodes, n->path, n);
|
||||
if (r < 0) {
|
||||
free(n->path);
|
||||
free(n);
|
||||
|
||||
Reference in New Issue
Block a user