diff options
author | Pavel Kirienko <pavel.kirienko@gmail.com> | 2015-04-23 22:02:34 +0300 |
---|---|---|
committer | Pavel Kirienko <pavel.kirienko@gmail.com> | 2015-04-23 22:02:34 +0300 |
commit | 3f961bf3c60c3ea380dc1dc62684a026667ec0e9 (patch) | |
tree | 51ca38b5d5586e065e85fb3816f510e481eaa520 /src/modules/uavcan | |
parent | b7b986359531add925da2eccf34e154851b414db (diff) | |
download | px4-firmware-3f961bf3c60c3ea380dc1dc62684a026667ec0e9.tar.gz px4-firmware-3f961bf3c60c3ea380dc1dc62684a026667ec0e9.tar.bz2 px4-firmware-3f961bf3c60c3ea380dc1dc62684a026667ec0e9.zip |
UAVCAN driver silently ignores repeated start commands without error. This allows to avoid error messages when UAVCAN driver is started from extras script before default initialization sequence is executed.
Diffstat (limited to 'src/modules/uavcan')
-rw-r--r-- | src/modules/uavcan/uavcan_main.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/uavcan/uavcan_main.cpp b/src/modules/uavcan/uavcan_main.cpp index 2d5abf959..f04ab9f17 100644 --- a/src/modules/uavcan/uavcan_main.cpp +++ b/src/modules/uavcan/uavcan_main.cpp @@ -698,7 +698,9 @@ int uavcan_main(int argc, char *argv[]) if (!std::strcmp(argv[1], "start")) { if (UavcanNode::instance()) { - errx(1, "already started"); + // Already running, no error + warnx("already started"); + ::exit(0); } // Node ID |