diff options
author | Karel Zak | 2017-05-18 11:39:34 +0200 |
---|---|---|
committer | Karel Zak | 2017-05-18 11:39:34 +0200 |
commit | 780ce22cdad01128139c1edfceb8f86338bf3dda (patch) | |
tree | bca21a46c58d6bf60ecaf59a4fa669c5a487d688 /sys-utils/wdctl.c | |
parent | tests: Fix UDF test output after changing UUID algorithm (diff) | |
download | kernel-qcow2-util-linux-780ce22cdad01128139c1edfceb8f86338bf3dda.tar.gz kernel-qcow2-util-linux-780ce22cdad01128139c1edfceb8f86338bf3dda.tar.xz kernel-qcow2-util-linux-780ce22cdad01128139c1edfceb8f86338bf3dda.zip |
misc: consolidate smartcols error messages
... just to keep translators happy
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/wdctl.c')
-rw-r--r-- | sys-utils/wdctl.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/sys-utils/wdctl.c b/sys-utils/wdctl.c index 441b7abf9..e47fc70e9 100644 --- a/sys-utils/wdctl.c +++ b/sys-utils/wdctl.c @@ -212,7 +212,7 @@ static void add_flag_line(struct libscols_table *table, struct wdinfo *wd, const line = scols_table_new_line(table, NULL); if (!line) { - warn(_("failed to initialize output line")); + warn(_("failed to allocate output line")); return; } @@ -239,8 +239,10 @@ static void add_flag_line(struct libscols_table *table, struct wdinfo *wd, const break; } - if (str) - scols_line_set_data(line, i, str); + if (str && scols_line_set_data(line, i, str)) { + warn(_("failed to add output data")); + break; + } } } @@ -256,7 +258,7 @@ static int show_flags(struct wdinfo *wd, uint32_t wanted) /* create output table */ table = scols_new_table(); if (!table) { - warn(_("failed to initialize output table")); + warn(_("failed to allocate output table")); return -1; } scols_table_enable_raw(table, raw); @@ -267,7 +269,7 @@ static int show_flags(struct wdinfo *wd, uint32_t wanted) struct colinfo *col = get_column_info(i); if (!scols_table_new_column(table, col->name, col->whint, col->flags)) { - warnx(_("failed to initialize output column")); + warnx(_("failed to allocate output column")); goto done; } } |