]> git.mxchange.org Git - flightgear.git/commitdiff
Fixed some compiler warnings.
authorThorstenB <brehmt@gmail.com>
Fri, 29 Oct 2010 19:14:09 +0000 (21:14 +0200)
committerThorstenB <brehmt@gmail.com>
Fri, 29 Oct 2010 19:14:09 +0000 (21:14 +0200)
Please the compiler (gods).

src/AIModel/AIBallistic.cxx
src/AIModel/AIWingman.cxx
src/Instrumentation/KLN89/kln89.cxx
src/Instrumentation/dclgps.cxx
src/Main/fg_os_osgviewer.cxx

index fa06b291e36de16f8a32f20e4708ccb6908c4a79..a0faf6eca02894ca8d72a7445ecd938424662dc1 100644 (file)
@@ -41,10 +41,12 @@ const double FGAIBallistic::slugs_to_lbs = 32.1740485564;
 FGAIBallistic::FGAIBallistic(object_type ot) :
 FGAIBase(ot),
 _height(0.0),
+_speed(0),
 _ht_agl_ft(0.0),
 _azimuth(0.0),
 _elevation(0.0),
 _rotation(0.0),
+hs(0),
 _elapsed_time(0),
 _aero_stabilised(false),
 _drag_area(0.007),
@@ -65,9 +67,7 @@ _report_impact(false),
 _external_force(false),
 _report_expiry(false),
 _impact_report_node(fgGetNode("/ai/models/model-impact", true)),
-hs(0),
-_old_height(0),
-_speed(0)
+_old_height(0)
 
 {
     no_roll = false;
index 6c93f395568124ef1e658ff57974d5f9565fc19d..7233abd2b5ec36a8d0c8974ff42c57218b146a0c 100644 (file)
@@ -29,9 +29,9 @@
 
 FGAIWingman::FGAIWingman() : FGAIBallistic(otWingman),
 _formate_to_ac(true),
-_break_angle(-90),
 _break(false),
 _join(false),
+_break_angle(-90),
 _coeff_hdg(5.0),
 _coeff_pch(5.0),
 _coeff_bnk(5.0),
index b074e229584c91f34703ac981118de29cb52bfe9..48d5646cadc0646fbb8be9d5dc8879bccaf224cf 100644 (file)
@@ -867,7 +867,7 @@ int KLN89::GetLabelQuadrant(double h1, double h2) {
        while(h2 < 0.0) h2 += 360.0;
        while(h2 > 360.0) h2 -= 360.0;
        double max_min_diff = 0.0;
-       int quad;
+       int quad = 1;
        for(int i=0; i<4; ++i) {
                double h = 45 + (90 * i);
                double diff1 = fabs(h - h1);
index 018e943c4cd62b4618360f664b5bf03dbbf9b9ae..41697092b3e928f8f27bec73f419d598dff91f1c 100644 (file)
@@ -635,7 +635,7 @@ void DCLGPS::update(double dt) {
 */
 string DCLGPS::ExpandSIAPIdent(const string& ident) {
        string name;
-       bool has_rwy;
+       bool has_rwy = false;
        
        switch(ident[0]) {
        case 'N': name = "NDB or GPS"; has_rwy = false; break;
index 483a7f4178387ba10e4e472ed3470277cd14829f..e2556f5b2ea12e5c2e274c4b0cfe043c7202a33e 100644 (file)
@@ -102,7 +102,7 @@ static osg::ref_ptr<osg::Camera> mainCamera;
 
 static void setStereoMode( const char * mode )
 {
-    DisplaySettings::StereoMode stereoMode;
+    DisplaySettings::StereoMode stereoMode = DisplaySettings::QUAD_BUFFER;
     bool stereoOn = true;
 
     if (strcmp(mode,"QUAD_BUFFER")==0)