Copter: resolve compiler warning re fence

This commit is contained in:
Randy Mackay 2013-05-04 23:18:16 +09:00
parent c20eac7a70
commit 6836964e3c
1 changed files with 2 additions and 2 deletions

View File

@ -74,10 +74,10 @@ static void fence_send_mavlink_status(mavlink_channel_t chan)
// traslate fence library breach types to mavlink breach types // traslate fence library breach types to mavlink breach types
uint8_t mavlink_breach_type = FENCE_BREACH_NONE; uint8_t mavlink_breach_type = FENCE_BREACH_NONE;
uint8_t breaches = fence.get_breaches(); uint8_t breaches = fence.get_breaches();
if (breaches & AC_FENCE_TYPE_ALT_MAX != 0) { if ((breaches & AC_FENCE_TYPE_ALT_MAX) != 0) {
mavlink_breach_type = FENCE_BREACH_MAXALT; mavlink_breach_type = FENCE_BREACH_MAXALT;
} }
if (breaches & AC_FENCE_TYPE_CIRCLE != 0) { if ((breaches & AC_FENCE_TYPE_CIRCLE) != 0) {
mavlink_breach_type = FENCE_BREACH_BOUNDARY; mavlink_breach_type = FENCE_BREACH_BOUNDARY;
} }