diff options
author | t0ni0 <azntonio789@gmail.com> | 2014-06-09 19:09:38 -0400 |
---|---|---|
committer | t0ni0 <azntonio789@gmail.com> | 2014-06-09 19:09:38 -0400 |
commit | d9b5efb263b61b8dc47ee63d7b4eb0b62853877a (patch) | |
tree | d29d05360801a5f9169c30f7ae160600132afa3f /src/modules | |
parent | 0a86fd0d9f3f3ba1a007ff54e1d498e7735d4aa5 (diff) | |
download | px4-firmware-d9b5efb263b61b8dc47ee63d7b4eb0b62853877a.tar.gz px4-firmware-d9b5efb263b61b8dc47ee63d7b4eb0b62853877a.tar.bz2 px4-firmware-d9b5efb263b61b8dc47ee63d7b4eb0b62853877a.zip |
Closed additional file descriptor
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/mc_pos_control/mc_pos_control_main.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/modules/mc_pos_control/mc_pos_control_main.cpp b/src/modules/mc_pos_control/mc_pos_control_main.cpp index 6a105762b..9d9d2a7c0 100644 --- a/src/modules/mc_pos_control/mc_pos_control_main.cpp +++ b/src/modules/mc_pos_control/mc_pos_control_main.cpp @@ -1071,6 +1071,12 @@ MulticopterPositionControl::task_main() _reset_pos_sp = true; reset_int_z = true; reset_int_xy = true; + + /* Close att_sp pub to allow offboard mode or att controller to advertise */ + if (_att_sp_pub > 0) { + close(_att_sp_pub); + _att_sp_pub = -1; + } } /* reset altitude controller integral (hovering throttle) to manual throttle after manual throttle control */ |