]> git.mxchange.org Git - simgear.git/commitdiff
Indentation fixes (and signed/unsigned comparison fix) to silence GCC 6 warnings
authorAlessandro Menti <alessandro.menti@hotmail.it>
Sun, 22 May 2016 17:14:42 +0000 (19:14 +0200)
committerRoland Haeder <roland@mxchange.org>
Sat, 13 Aug 2016 08:21:16 +0000 (10:21 +0200)
simgear/canvas/ShivaVG/src/shPipeline.c
simgear/environment/metar.cxx
simgear/package/Root.cxx
simgear/sound/sample_openal.cxx

index 4eb2fd27c6fd1b74a6c12990a5a2bddddac0cf59..c3eb85cd49d8373e368f07077f7f44cac208acfb 100644 (file)
@@ -80,8 +80,12 @@ void updateBlendingStateGL(VGContext *c, int alphaIsOne)
 
   case VG_BLEND_SRC_OVER: default:
     glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
-    if (alphaIsOne) glDisable(GL_BLEND);
-    else glEnable(GL_BLEND); break;
+    if (alphaIsOne) {
+      glDisable(GL_BLEND);
+    } else {
+      glEnable(GL_BLEND);
+    }
+    break;
   };
 }
 
index 4e96839cbd8fefdd4aa7914c69a55c4ff9319e85..5b497a05a5781589ce3aa47b87920635fbd13f02 100644 (file)
@@ -648,10 +648,11 @@ bool SGMetar::scanWeather()
        weather = pre + weather + post;
        weather.erase(weather.length() - 1);
        _weather.push_back(weather);
-    if( ! w.phenomena.empty() )
+    if( ! w.phenomena.empty() ) {
         _weather2.push_back( w );
-       _grpcount++;
-       return true;
+    }
+    _grpcount++;
+    return true;
 }
 
 
index d6460ace9aa921d7fd6bb0485ab86c258b0a8c9c..1aaf773c672bd35a8ba1d7b7a4134f8a4b9f719f 100644 (file)
@@ -384,7 +384,7 @@ void Root::refresh(bool aForce)
     CatalogList toRefresh;
     CatalogDict::iterator it = d->catalogs.begin();
     for (; it != d->catalogs.end(); ++it) {
-        int age = it->second->ageInSeconds();
+        unsigned int age = it->second->ageInSeconds();
         if (aForce || (age > maxAgeSeconds())) {
             toRefresh.push_back(it->second);
         }
index 95a6077559822deda6ff7e0f99a67cfc02eba758..3bb124bc8dfdf46a1be1fd6bc7c7c0b89e7ce158 100644 (file)
@@ -260,5 +260,8 @@ SGPath SGSoundSample::file_path() const
 
 void SGSoundSample::free_data()
 {
-   if ( _data != NULL ) free( _data ); _data = NULL;
+   if ( _data != NULL ) {
+     free( _data );
+   }
+   _data = NULL;
 }