AP_Var: fixed a logic bug in APVar::key()

We were using && instead of & for a bit check. Thanks to Mike for
spotting this!

Pair-Programmed-With: Mike Smith

git-svn-id: https://arducopter.googlecode.com/svn/trunk@3232 f9c3cf11-9bcb-44bc-f272-b75c42450872
This commit is contained in:
tridge60@gmail.com 2011-09-04 06:39:40 +00:00
parent b8b8b7e8ca
commit e099079cc0
1 changed files with 1 additions and 1 deletions

View File

@ -338,7 +338,7 @@ AP_Var::key(void)
if (_group) { // group members don't have keys
return k_key_none;
}
if (_key && k_key_not_located) { // if not located, key is in memory
if (_key & k_key_not_located) { // if not located, key is in memory
return _key & k_key_mask;
}