diff --git a/src/Instrumentation/HUD/HUD_runway.cxx b/src/Instrumentation/HUD/HUD_runway.cxx index 6f4b13617..b7d0b0a66 100644 --- a/src/Instrumentation/HUD/HUD_runway.cxx +++ b/src/Instrumentation/HUD/HUD_runway.cxx @@ -136,10 +136,10 @@ void HUD::Runway::draw() glEnable(GL_LINE_STIPPLE); glLineStipple(1, _stipple_out); anyLines = - drawLine(_points3d[0], _points3d[1], _points2d[0], _points2d[1]) | //draw top - drawLine(_points3d[2], _points3d[1], _points2d[2], _points2d[1]) | //draw right - drawLine(_points3d[2], _points3d[3], _points2d[2], _points2d[3]) | //draw bottom - drawLine(_points3d[3], _points3d[0], _points2d[3], _points2d[0]); //draw left + drawLine(_points3d[0], _points3d[1], _points2d[0], _points2d[1]) || //draw top + drawLine(_points3d[2], _points3d[1], _points2d[2], _points2d[1]) || //draw right + drawLine(_points3d[2], _points3d[3], _points2d[2], _points2d[3]) || //draw bottom + drawLine(_points3d[3], _points3d[0], _points2d[3], _points2d[0]); //draw left glLineStipple(1, _stipple_center); anyLines |= drawLine(_points3d[5], _points3d[4], _points2d[5], _points2d[4]); //draw center diff --git a/src/Network/Swift/plugin.cpp b/src/Network/Swift/plugin.cpp index 1cd7826c6..74172f604 100644 --- a/src/Network/Swift/plugin.cpp +++ b/src/Network/Swift/plugin.cpp @@ -15,13 +15,6 @@ #include #include -namespace { -inline std::string fgswiftbusServiceName() -{ - return "org.swift-project.fgswiftbus"; -} -} // namespace - namespace FGSwiftBus { CPlugin::CPlugin() { diff --git a/src/Network/Swift/plugin.h b/src/Network/Swift/plugin.h index d494acd99..cc3ee24c6 100644 --- a/src/Network/Swift/plugin.h +++ b/src/Network/Swift/plugin.h @@ -50,7 +50,6 @@ private: std::unique_ptr m_traffic; std::thread m_dbusThread; - bool m_isRunning = false; bool m_shouldStop = false; }; } // namespace FGSwiftBus diff --git a/src/Traffic/Schedule.cxx b/src/Traffic/Schedule.cxx index 9cc33deac..6baebd717 100644 --- a/src/Traffic/Schedule.cxx +++ b/src/Traffic/Schedule.cxx @@ -583,16 +583,13 @@ FGScheduledFlight* FGAISchedule::findAvailableFlight(const string& currentDestin if (fltBegin == fltEnd) { SG_LOG(SG_AI, SG_BULK, "No Flights Scheduled for " << req); } - int counter = 0; + for (FGScheduledFlightVecIterator i = fltBegin; i != fltEnd; ++i) { (*i)->adjustTime(now); - //sort(fltBegin, fltEnd, compareScheduledFlights); - //cerr << counter++ << endl; } std::sort(fltBegin, fltEnd, FGScheduledFlight::compareScheduledFlights); for (FGScheduledFlightVecIterator i = fltBegin; i != fltEnd; ++i) { //bool valid = true; - counter++; if (!(*i)->isAvailable()) { SG_LOG(SG_AI, SG_BULK, "" << (*i)->getCallSign() << "is no longer available"); diff --git a/utils/GPSsmooth/MIDG_main.cxx b/utils/GPSsmooth/MIDG_main.cxx index 784bba0d8..56ee7023d 100644 --- a/utils/GPSsmooth/MIDG_main.cxx +++ b/utils/GPSsmooth/MIDG_main.cxx @@ -8,6 +8,7 @@ # include // htonl() ntohl() #endif +#include #include #include @@ -574,19 +575,19 @@ int main( int argc, char **argv ) { SGSerialPort input( serialdev, 115200 ); if ( !input.is_enabled() ) { cout << "Cannot open: " << serialdev << endl; - return false; + return EXIT_FAILURE; } // open up the data log file if requested if ( !outfile.length() ) { cout << "no --outfile specified, cannot capture data!" << endl; - return false; + return EXIT_FAILURE; } SGFile output( outfile ); if ( !output.open( SG_IO_OUT ) ) { cout << "Cannot open: " << outfile << endl; - return false; + return EXIT_FAILURE; } while ( input.is_enabled() ) { diff --git a/utils/GPSsmooth/UGear_main.cxx b/utils/GPSsmooth/UGear_main.cxx index afa6cefc3..6cbde17ff 100644 --- a/utils/GPSsmooth/UGear_main.cxx +++ b/utils/GPSsmooth/UGear_main.cxx @@ -8,6 +8,7 @@ # include // htonl() ntohl() #endif +#include #include #include @@ -990,7 +991,6 @@ int main( int argc, char **argv ) { } else if ( serialdev.length() ) { // process incoming data from the serial port - int count = 0; double current_time = 0.0; double last_time = 0.0; @@ -1012,19 +1012,19 @@ int main( int argc, char **argv ) { SGSerialPort uavcom( serialdev, 115200 ); if ( !uavcom.is_enabled() ) { cout << "Cannot open: " << serialdev << endl; - return false; + return EXIT_FAILURE; } // open up the data log file if requested if ( !outfile.length() ) { cout << "no --outfile specified, cannot capture data!" << endl; - return false; + return EXIT_FAILURE; } SGFile log( outfile ); if ( !log.open( SG_IO_OUT ) ) { cout << "Cannot open: " << outfile << endl; - return false; + return EXIT_FAILURE; } // add some test commands @@ -1039,7 +1039,6 @@ int main( int argc, char **argv ) { &imupacket, &navpacket, &servopacket, &healthpacket, ignore_checksum ); // cout << "message id = " << id << endl; - count++; telnet.process();