paparazzi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[paparazzi-commits] [4856] add missing default: entries in switch


From: Pascal Brisset
Subject: [paparazzi-commits] [4856] add missing default: entries in switch
Date: Thu, 22 Apr 2010 10:57:44 +0000

Revision: 4856
          http://svn.sv.gnu.org/viewvc/?view=rev&root=paparazzi&revision=4856
Author:   hecto
Date:     2010-04-22 10:57:44 +0000 (Thu, 22 Apr 2010)
Log Message:
-----------
 add missing default: entries in switch

Modified Paths:
--------------
    paparazzi3/trunk/sw/airborne/fw_v_ctl.c
    paparazzi3/trunk/sw/airborne/nav.c
    paparazzi3/trunk/sw/airborne/nav_line.c

Modified: paparazzi3/trunk/sw/airborne/fw_v_ctl.c
===================================================================
--- paparazzi3/trunk/sw/airborne/fw_v_ctl.c     2010-04-22 10:56:04 UTC (rev 
4855)
+++ paparazzi3/trunk/sw/airborne/fw_v_ctl.c     2010-04-22 10:57:44 UTC (rev 
4856)
@@ -185,6 +185,7 @@
 void v_ctl_climb_loop ( void ) {
   switch (v_ctl_climb_mode) {
   case V_CTL_CLIMB_MODE_AUTO_THROTTLE:
+  default:
     v_ctl_climb_auto_throttle_loop();
     break;
 #ifdef V_CTL_AUTO_PITCH_PGAIN
@@ -250,6 +251,7 @@
     
   case V_CTL_AUTO_THROTTLE_STANDARD:
 #endif
+  default:
     f_throttle = controlled_throttle;
     v_ctl_auto_throttle_sum_err += err;
     BoundAbs(v_ctl_auto_throttle_sum_err, V_CTL_AUTO_THROTTLE_MAX_SUM_ERR);

Modified: paparazzi3/trunk/sw/airborne/nav.c
===================================================================
--- paparazzi3/trunk/sw/airborne/nav.c  2010-04-22 10:56:04 UTC (rev 4855)
+++ paparazzi3/trunk/sw/airborne/nav.c  2010-04-22 10:57:44 UTC (rev 4856)
@@ -558,6 +558,9 @@
       InitStage();
     }
     return;
+
+  default:/* Should not occur !!! Doing nothing */
+    return;
   } /* switch */
 }
 
@@ -649,5 +652,8 @@
       InitStage();
     }
     return;
+
+ default: /* Should not occur !!! Doing nothing */
+   return;
   }
 }

Modified: paparazzi3/trunk/sw/airborne/nav_line.c
===================================================================
--- paparazzi3/trunk/sw/airborne/nav_line.c     2010-04-22 10:56:04 UTC (rev 
4855)
+++ paparazzi3/trunk/sw/airborne/nav_line.c     2010-04-22 10:57:44 UTC (rev 
4856)
@@ -138,6 +138,8 @@
       line_status = LR12;
       nav_init_stage();
     }
+  default: /* Should not occur !!! End the pattern */
+    return FALSE;
   }
   return TRUE; /* This pattern never ends */
 }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]