Rename stop-all to stop for MAVLink, but still keep stop-all for existing scripts

This commit is contained in:
Lorenz Meier 2016-04-10 11:18:05 -07:00
parent 8b876e6497
commit d2c98a98e9

View File

@ -2398,7 +2398,7 @@ Mavlink::stream_command(int argc, char *argv[])
static void usage()
{
warnx("usage: mavlink {start|stop-all|stream} [-d device] [-u network_port] [-o remote_port] [-t partner_ip] [-b baudrate]\n\t[-r rate][-m mode] [-s stream] [-f] [-p] [-v] [-w] [-x]");
warnx("usage: mavlink {start|stop|stream} [-d device] [-u network_port] [-o remote_port] [-t partner_ip] [-b baudrate]\n\t[-r rate][-m mode] [-s stream] [-f] [-p] [-v] [-w] [-x]");
}
int mavlink_main(int argc, char *argv[])
@ -2416,7 +2416,7 @@ int mavlink_main(int argc, char *argv[])
usage();
return 1;
} else if (!strcmp(argv[1], "stop-all")) {
} else if (!strcmp(argv[1], "stop") || !strcmp(argv[1], "stop-all") ) {
return Mavlink::destroy_all_instances();
} else if (!strcmp(argv[1], "status")) {