[yelp] Add parentheses around assignments used as truth



commit 32b46e6117923dcff9d64683e4fbedc7c32bea0a
Author: David King <amigadave amigadave com>
Date:   Mon Feb 9 21:26:19 2015 +0000

    Add parentheses around assignments used as truth
    
    Avoid compiler warnings.

 libyelp/yelp-help-list.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/libyelp/yelp-help-list.c b/libyelp/yelp-help-list.c
index f65ebb2..5607761 100644
--- a/libyelp/yelp-help-list.c
+++ b/libyelp/yelp-help-list.c
@@ -246,7 +246,7 @@ help_list_think (YelpHelpList *list)
             g_free (helpdirname);
             continue;
         }
-        while (child = g_file_enumerator_next_file (children, NULL, NULL)) {
+        while ((child = g_file_enumerator_next_file (children, NULL, NULL))) {
             gchar *docid;
             HelpListEntry *entry = NULL;
 
@@ -323,7 +323,7 @@ help_list_think (YelpHelpList *list)
                 g_free (langdirname);
                 continue;
             }
-            while (child = g_file_enumerator_next_file (children, NULL, NULL)) {
+            while ((child = g_file_enumerator_next_file (children, NULL, NULL))) {
                 gchar *docid, *filename;
                 HelpListEntry *entry = NULL;
                 if (g_file_info_get_file_type (child) != G_FILE_TYPE_DIRECTORY) {


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