summaryrefslogtreecommitdiffstats
path: root/src/command_line_options.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/command_line_options.cpp')
-rw-r--r--src/command_line_options.cpp56
1 files changed, 28 insertions, 28 deletions
diff --git a/src/command_line_options.cpp b/src/command_line_options.cpp
index 2018760..0f26edf 100644
--- a/src/command_line_options.cpp
+++ b/src/command_line_options.cpp
@@ -6,39 +6,39 @@
CommandLineOptions::CommandLineOptions(int argc, char * const argv[]) {
// parse command line arguments (please sort by short option for easier handling)
static const struct option longOptions[] = {
- {"allow-vm-edit", no_argument, NULL, 'vmed'},
- {"autoquit", required_argument, NULL, 'aqit'},
- {"base", required_argument, NULL, 'b'},
- {"path", required_argument, NULL, 'b'}, // Compatibility to v1.0
- {"config", required_argument, NULL, 'c'},
- {"debug", no_argument, NULL, 'D'},
- {"default", required_argument, NULL, 'd'},
- {"exam-mode", no_argument, NULL, 'exms'},
- {"fullscreen", no_argument, NULL, 'F'},
- {"file", required_argument, NULL, 'f'},
- {"help", no_argument, NULL, 'h'},
- {"locations", required_argument, NULL, 'l'},
- {"pool", required_argument, NULL, 'P'},
- {"pvs", no_argument, NULL, 'p'},
- {"pvs-checked", no_argument, NULL, 'pvck'},
- {"runscript", no_argument, NULL, 'S'},
- {"size", required_argument, NULL, 's'},
- {"tab", required_argument, NULL, 'T'},
- {"theme", required_argument, NULL, 't'},
- {"url", required_argument, NULL, 'u'},
- {"version", no_argument, NULL, 'v'},
- {"xpath", required_argument, NULL, 'x'},
- {"location-mode", required_argument, NULL, 'locm'},
- {"template-mode", required_argument, NULL, 'tmpm'},
- {"start-uuid", required_argument, NULL, 'uuid'},
- {"no-vtx", no_argument, NULL, 'nvtx'},
- {0, 0, 0, 0}
+ {"allow-vm-edit", no_argument, nullptr, 'vmed'},
+ {"autoquit", required_argument, nullptr, 'aqit'},
+ {"base", required_argument, nullptr, 'b'},
+ {"path", required_argument, nullptr, 'b'}, // Compatibility to v1.0
+ {"config", required_argument, nullptr, 'c'},
+ {"debug", no_argument, nullptr, 'D'},
+ {"default", required_argument, nullptr, 'd'},
+ {"exam-mode", no_argument, nullptr, 'exms'},
+ {"fullscreen", no_argument, nullptr, 'F'},
+ {"file", required_argument, nullptr, 'f'},
+ {"help", no_argument, nullptr, 'h'},
+ {"locations", required_argument, nullptr, 'l'},
+ {"pool", required_argument, nullptr, 'P'},
+ {"pvs", no_argument, nullptr, 'p'},
+ {"pvs-checked", no_argument, nullptr, 'pvck'},
+ {"runscript", no_argument, nullptr, 'S'},
+ {"size", required_argument, nullptr, 's'},
+ {"tab", required_argument, nullptr, 'T'},
+ {"theme", required_argument, nullptr, 't'},
+ {"url", required_argument, nullptr, 'u'},
+ {"version", no_argument, nullptr, 'v'},
+ {"xpath", required_argument, nullptr, 'x'},
+ {"location-mode", required_argument, nullptr, 'locm'},
+ {"template-mode", required_argument, nullptr, 'tmpm'},
+ {"start-uuid", required_argument, nullptr, 'uuid'},
+ {"no-vtx", no_argument, nullptr, 'nvtx'},
+ {nullptr, 0, nullptr, 0}
};
int c;
// Again, please sort alphabetically in getopt_long call and switch statement
- while ((c = getopt_long(argc, argv, "b:c:Dd:Ff:hl:P:pSs:t:T:u:vx:?", longOptions, NULL)) != -1) {
+ while ((c = getopt_long(argc, argv, "b:c:Dd:Ff:hl:P:pSs:t:T:u:vx:?", longOptions, nullptr)) != -1) {
switch (c) {
case 'aqit':
options.insert("autoquit", optarg);