From: Zbigniew Jędrzejewski-Szmek Date: Tue, 30 Sep 2014 11:44:04 +0000 (-0400) Subject: shared: util - use nicer idiom to silence Coverity X-Git-Tag: v217~388 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;ds=sidebyside;h=acb3b3ddc082880eaaa1d7773296ad9abd756f23;p=elogind.git shared: util - use nicer idiom to silence Coverity Change the other spot too. --- diff --git a/src/shared/util.c b/src/shared/util.c index ebacee55b..bbd9bd11d 100644 --- a/src/shared/util.c +++ b/src/shared/util.c @@ -3306,13 +3306,8 @@ unsigned lines(void) { l = 0; e = getenv("LINES"); - if (e) { - int r; - - r = safe_atou(e, &l); - if (r < 0) {} - /* do nothing, we fall back to l = 0 */ - } + if (e) + (void) safe_atou(e, &l); if (l <= 0) l = fd_lines(STDOUT_FILENO);