Changeset 291 in flair-src


Ignore:
Timestamp:
Jan 9, 2019, 1:58:48 PM (6 years ago)
Author:
Sanahuja Guillaume
Message:

add exit failure

Location:
trunk/demos
Files:
13 edited

Legend:

Unmodified
Added
Removed
  • trunk/demos/CircleFollower/simulator/src/main.cpp

    r240 r291  
    8585  } catch(ArgException& e) {
    8686    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     87    exit(EXIT_FAILURE);
    8788  }
    8889}
  • trunk/demos/CircleFollower/uav/src/main.cpp

    r263 r291  
    9595        } catch (ArgException &e) { // catch any exceptions
    9696        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     97        exit(EXIT_FAILURE);
    9798        }
    9899}
  • trunk/demos/Gps/simulator/src/main.cpp

    r158 r291  
    8585  } catch(ArgException& e) {
    8686    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     87    exit(EXIT_FAILURE);
    8788  }
    8889}
  • trunk/demos/Gps/uav/src/main.cpp

    r185 r291  
    9494        } catch (ArgException &e) { // catch any exceptions
    9595        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     96        exit(EXIT_FAILURE);
    9697        }
    9798}
  • trunk/demos/OpticalFlow/simulator/src/main.cpp

    r158 r291  
    8585  {
    8686    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     87    exit(EXIT_FAILURE);
    8788  }
    8889}
  • trunk/demos/OpticalFlow/uav/src/main.cpp

    r137 r291  
    106106        address=addressArg.getValue();
    107107
    108         } catch (ArgException &e)  // catch any exceptions
    109         { cerr << "error: " << e.error() << " for arg " << e.argId() << endl; }
     108        } catch (ArgException &e) {
     109        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     110        exit(EXIT_FAILURE);
     111    }
    110112}
  • trunk/demos/PidStandalone/simulator/src/main.cpp

    r236 r291  
    8484#endif
    8585
    86         } catch (ArgException &e)  // catch any exceptions
    87         { cerr << "error: " << e.error() << " for arg " << e.argId() << endl; }
     86        } catch (ArgException &e) {
     87        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     88        exit(EXIT_FAILURE);   
     89    }
    8890}
    8991
  • trunk/demos/PidStandalone/uav/src/main.cpp

    r236 r291  
    115115    headless = headlessArg.getValue();
    116116
    117   } catch (ArgException &e) // catch any exceptions
    118   {
     117  } catch (ArgException &e) {
    119118    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     119    exit(EXIT_FAILURE);
    120120  }
    121121}
  • trunk/demos/SimpleFleet/simulator/src/main.cpp

    r158 r291  
    7777
    7878
    79         } catch (ArgException &e)  // catch any exceptions
    80         { cerr << "error: " << e.error() << " for arg " << e.argId() << endl; }
     79        } catch (ArgException &e) {
     80        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     81        exit(EXIT_FAILURE);
     82    }
    8183}
    8284
  • trunk/demos/SimpleFleet/uav/src/main.cpp

    r137 r291  
    100100        } catch (ArgException &e) { // catch any exceptions
    101101        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     102        exit(EXIT_FAILURE);
    102103        }
    103104}
  • trunk/demos/Sinus/src/main.cpp

    r16 r291  
    9494  } catch (ArgException &e) { // catch any exceptions
    9595    cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     96    exit(EXIT_FAILURE);
    9697  }
    9798}
  • trunk/demos/Skeletons/CustomReferenceAngles/src/main.cpp

    r137 r291  
    9393        } catch (ArgException &e) { // catch any exceptions
    9494        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     95        exit(EXIT_FAILURE);
    9596        }
    9697}
  • trunk/demos/Skeletons/CustomTorques/src/main.cpp

    r137 r291  
    9494        } catch (ArgException &e) { // catch any exceptions
    9595        cerr << "error: " << e.error() << " for arg " << e.argId() << endl;
     96        exit(EXIT_FAILURE);
    9697        }
    9798}
Note: See TracChangeset for help on using the changeset viewer.