summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2005-08-25 15:10:03 +0000
committerSascha Hauer <s.hauer@pengutronix.de>2005-08-25 15:10:03 +0000
commit1fe44436c7de0efd86716f9e24d1cd505c8981da (patch)
tree9e7db6151f747a999bffe9a7e3d3c1aa6e070163
parentac8302a72441b03ddf2420b3aaf9a7e7ba5ecbca (diff)
downloadcanutils-1fe44436c7de0efd86716f9e24d1cd505c8981da.tar.gz
some option parsing fixes
git-svn-id: https://iocaste.extern.pengutronix.de/svn/canutils/trunks/canutils-1.0-trunk@36 5fd5a299-6ef2-0310-aa18-8b01d7c39d8c
-rw-r--r--candump.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/candump.c b/candump.c
index b8ceb8d..9c1b81c 100644
--- a/candump.c
+++ b/candump.c
@@ -29,9 +29,10 @@ void print_usage(char *prg)
{
fprintf(stderr, "Usage: %s <can-interface> [Options]\n"
"Options:\n"
- " -f, --family=FAMILY Protocol family (default PF_CAN = %d)\n"
- " -t, --type=TYPE Socket type, see man 2 socket (default SOCK_RAW = %d)\n"
+ " -f, --family=FAMILY protocol family (default PF_CAN = %d)\n"
+ " -t, --type=TYPE socket type, see man 2 socket (default SOCK_RAW = %d)\n"
" -p, --protocol=PROTO CAN protocol (default CAN_PROTO_RAW = %d)\n"
+ " -h, --help this help\n"
" --version print version information and exit\n",
prg, PF_CAN, SOCK_RAW, CAN_PROTO_RAW);
}
@@ -62,7 +63,7 @@ int main(int argc, char **argv)
{ 0, 0, 0, 0},
};
- while ((opt = getopt_long(argc, argv, "f:t:p:m:v:", long_options, NULL)) != -1) {
+ while ((opt = getopt_long(argc, argv, "f:t:p:", long_options, NULL)) != -1) {
switch (opt) {
case 'h':
print_usage(basename(argv[0]));