1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-28 20:25:38 +03:00

Merge pull request #3215 from keszybz/news-and-other-small-cleanups

News and other small cleanups
This commit is contained in:
Lennart Poettering 2016-05-07 18:40:57 +02:00
commit e76f4732f1
2 changed files with 12 additions and 12 deletions

9
NEWS
View File

@ -101,7 +101,8 @@ CHANGES WITH 230 in spe:
* "systemctl show" gained a new --value switch, which allows print a
only the contents of a specific unit property, without also printing
the property's name.
the property's name. Similar support was added to "show*" verbs
of loginctl and machinectl that output "key=value" lists.
* A new command "systemctl revert" has been added that may be used to
revert to the vendor version of a unit file, in case local changes
@ -142,9 +143,9 @@ CHANGES WITH 230 in spe:
changed to use this functionality by default.
* The default start timeout may now be configured on the kernel command
line via systemd.default_timeout_start_sec=. It was configurable
previously via the DefaultTimeoutStartSec= option in
/etc/systemd/system.conf already.
line via systemd.default_timeout_start_sec=. It was already
configurable via the DefaultTimeoutStartSec= option in
/etc/systemd/system.conf.
* Socket units gained a new TriggerLimitIntervalSec= and
TriggerLimitBurst= setting to configure a limit on the activation

View File

@ -1355,7 +1355,7 @@ static void output_unit_file_list(const UnitFileList *units, unsigned c) {
} else
id_cols = max_id_len;
if (!arg_no_legend)
if (!arg_no_legend && c > 0)
printf("%-*s %-*s\n",
id_cols, "UNIT FILE",
state_cols, "STATE");
@ -1422,8 +1422,8 @@ static int list_unit_files(int argc, char *argv[], void *userdata) {
n_units = hashmap_size(h);
units = new(UnitFileList, n_units);
if (!units && n_units > 0) {
units = new(UnitFileList, n_units ?: 1); /* avoid malloc(0) */
if (!units) {
unit_file_list_free(h);
return log_oom();
}
@ -1519,10 +1519,9 @@ static int list_unit_files(int argc, char *argv[], void *userdata) {
qsort_safe(units, c, sizeof(UnitFileList), compare_unit_file_list);
output_unit_file_list(units, c);
if (install_client_side()) {
if (install_client_side())
for (unit = units; unit < units + c; unit++)
free(unit->path);
}
return 0;
}