Fix:core:Fix clang compiler warnings: Add missing parentheses
authorrikky <rikky@ffa7fe5e-494d-0410-b361-a75ebd5db220>
Sat, 12 Feb 2011 00:30:38 +0000 (00:30 +0000)
committerrikky <rikky@ffa7fe5e-494d-0410-b361-a75ebd5db220>
Sat, 12 Feb 2011 00:30:38 +0000 (00:30 +0000)
git-svn-id: https://navit.svn.sourceforge.net/svnroot/navit/trunk@4142 ffa7fe5e-494d-0410-b361-a75ebd5db220

navit/navit/maptool/boundaries.c
navit/navit/xmlconfig.c

index 439e02b..9268851 100644 (file)
@@ -101,7 +101,7 @@ test(GList *boundaries_list)
        struct item_bin *ib;
        FILE *f=fopen("country_276.bin.unsorted","r");
        printf("start\n");
-       while (ib=read_item(f)) {
+       while ((ib=read_item(f))) {
                struct coord *c=(struct coord *)(ib+1);
                char *name=item_bin_get_attr(ib, attr_town_name, NULL);
                printf("%s:",name);
@@ -148,7 +148,7 @@ process_boundaries(FILE *boundaries, FILE *ways)
 
        member_hash=g_hash_table_new_full(boundary_member_hash, boundary_member_equal, NULL, NULL);
        boundaries_list=build_boundaries(boundaries);
-       while (ib=read_item(ways)) {
+       while ((ib=read_item(ways))) {
                long long *wayid=item_bin_get_attr(ib, attr_osm_wayid, NULL);
                if (wayid) {
                        GList *l=g_hash_table_lookup(member_hash, wayid);
index 84b6e35..03fc007 100644 (file)
@@ -1081,7 +1081,7 @@ parse_file(struct xmldocument *document, xmlerror **error)
        xmlfile=getenv("XMLFILE");
        newxmlfile=g_strdup(document->href);
        newxmldir=g_strdup(document->href);
-       if (sep=strrchr(newxmldir,'/')) 
+       if ((sep=strrchr(newxmldir,'/'))) 
                *sep='\0';
        else {
                g_free(newxmldir);