mirror of
https://github.com/systemd/systemd
synced 2024-10-15 12:34:37 +00:00
systemctl: do not print items twice in list-dependencies
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1807485.
This commit is contained in:
parent
dd0395b565
commit
dbf2801f5a
|
@ -785,6 +785,8 @@ static int list_dependencies_get_dependencies(sd_bus *bus, const char *name, cha
|
|||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to get properties of %s: %s", name, bus_error_message(&error, r));
|
||||
|
||||
strv_uniq(deps); /* Sometimes a unit might have multiple deps on the other unit,
|
||||
* but we still want to show it just once. */
|
||||
*ret = TAKE_PTR(deps);
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in a new issue