From 1ce46fcf6bf581b40b5214747142ce69608e4b89 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Wed, 17 May 2017 12:50:36 +0200 Subject: [PATCH] libsmartcols: check scols_table_set_default_symbols() return code [coverity scan] Signed-off-by: Karel Zak --- libsmartcols/src/table_print.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libsmartcols/src/table_print.c b/libsmartcols/src/table_print.c index 2377a0063a..8cd737c8ba 100644 --- a/libsmartcols/src/table_print.c +++ b/libsmartcols/src/table_print.c @@ -1375,7 +1375,9 @@ static int initialize_printing(struct libscols_table *tb, struct libscols_buffer DBG(TAB, ul_debugobj(tb, "initialize printing")); if (!tb->symbols) { - scols_table_set_default_symbols(tb); + rc = scols_table_set_default_symbols(tb); + if (rc) + goto err; tb->priv_symbols = 1; } else tb->priv_symbols = 0; -- 2.47.2