cgtop: minimize aux variable scope
This commit is contained in:
parent
cf6f7f66a4
commit
bdc49d4491
|
@ -868,14 +868,16 @@ static int get_cgroup_root(char **ret) {
|
|||
_cleanup_(sd_bus_error_free) sd_bus_error error = SD_BUS_ERROR_NULL;
|
||||
_cleanup_(sd_bus_flush_close_unrefp) sd_bus *bus = NULL;
|
||||
_cleanup_free_ char *unit = NULL, *path = NULL;
|
||||
char *aux;
|
||||
const char *m;
|
||||
int r;
|
||||
|
||||
if (arg_root) {
|
||||
char *aux;
|
||||
|
||||
aux = strdup(arg_root);
|
||||
if (!aux)
|
||||
return log_oom();
|
||||
|
||||
*ret = aux;
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue