[libglnx] console: trim useless check



commit e226ccf6913d1d852fde1e150a99fab508f85c34
Author: Jonathan Lebon <jlebon redhat com>
Date:   Tue Aug 15 15:23:58 2017 -0400

    console: trim useless check
    
    The `percentage` var is a guint and so is always >= 0.
    
    Coverity CID: 163703

 glnx-console.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/glnx-console.c b/glnx-console.c
index 785f348..c6d9331 100644
--- a/glnx-console.c
+++ b/glnx-console.c
@@ -275,7 +275,7 @@ void
 glnx_console_progress_text_percent (const char *text,
                                     guint percentage)
 {
-  g_return_if_fail (percentage >= 0 && percentage <= 100);
+  g_return_if_fail (percentage <= 100);
 
   text_percent_internal (text, percentage);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]