GCS_MAVLink: Do not compare delegate to NULL

Use the simpler "if (delegate_name)" since it allows simpler
implementation in the class, i.e. the bool operator rather than having
to compare to another object.
This commit is contained in:
Lucas De Marchi 2015-05-24 07:41:34 -03:00 committed by Andrew Tridgell
parent ff398dbf0c
commit 82d22992bd
1 changed files with 1 additions and 1 deletions

View File

@ -840,7 +840,7 @@ GCS_MAVLINK::update(run_cli_fn run_cli)
{
uint8_t c = comm_receive_ch(chan);
if (run_cli != NULL) {
if (run_cli) {
/* allow CLI to be started by hitting enter 3 times, if no
* heartbeat packets have been received */
if ((mavlink_active==0) && (hal.scheduler->millis() - _cli_timeout) < 20000 &&