]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/JSBSim/FGTank.cpp
Check return value of FDM::init().
[flightgear.git] / src / FDM / JSBSim / FGTank.cpp
index 22a6113441481c2a57ffd6617f9f49fbd8eefc8d..922ff8d0daec313b42298bbffd051a584300ddf2 100644 (file)
@@ -35,8 +35,12 @@ HISTORY
 ********************************************************************************
 INCLUDES
 *******************************************************************************/
+
 #include "FGTank.h"
 
+static const char *IdSrc = "$Header$";
+static const char *IdHdr = ID_TANK;
+
 /*******************************************************************************
 ************************************ CODE **************************************
 *******************************************************************************/
@@ -58,11 +62,12 @@ FGTank::FGTank(FGConfigFile* AC_cfg)
   *AC_cfg >> Capacity;                          // pounds (amount it can hold)
   *AC_cfg >> Contents;                          // pounds  (amount it is holding)
   Selected = true;
-  if(Capacity != 0)
+
+  if (Capacity != 0) {
     PctFull = 100.0*Contents/Capacity;            // percent full; 0 to 100.0
-  else {
-    Contents=0;
-    PctFull=0;
+  else {
+    Contents = 0;
+    PctFull  = 0;
   }     
 }