aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLaurent Ghigonis <laurent@p1sec.com>2013-06-27 23:37:38 +0200
committerLaurent Ghigonis <laurent@p1sec.com>2013-06-27 23:37:38 +0200
commit551f2fd80d8bc11e92391cb20c180dbde573db86 (patch)
tree82b97f20840cec6848aa703b1714b4a0747fda5d
parentlibglouglou: traceroute: handle multiple header inclusions (diff)
downloadglouglou-551f2fd80d8bc11e92391cb20c180dbde573db86.tar.xz
glouglou-551f2fd80d8bc11e92391cb20c180dbde573db86.zip
gg_map: improve argparse
-rw-r--r--gg_map/gg_map.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gg_map/gg_map.c b/gg_map/gg_map.c
index a73042f..73f125e 100644
--- a/gg_map/gg_map.c
+++ b/gg_map/gg_map.c
@@ -373,8 +373,8 @@ elm_main(int argc, char **argv)
}
}
switch (argc - optind) {
- case 2: gg_serv_port = atoi(argv[3]);
- case 1: strncpy(gg_serv_ip, argv[2], sizeof(gg_serv_ip));
+ case 2: gg_serv_port = atoi(argv[2]);
+ case 1: strncpy(gg_serv_ip, argv[1], sizeof(gg_serv_ip));
case 0:
break;
default: