summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2010-04-07 15:15:06 +0200
committerGravatar Martin Szulecki2010-04-07 15:15:06 +0200
commit25103d3343074b61c6e2311324ccc92fc07e9105 (patch)
treecabd9eaf3310b67897cc1cc93e6bb34dec77e988
parent5acdb60f197b192f475373a710077c62b6d6f4f3 (diff)
downloadideviceinstaller-25103d3343074b61c6e2311324ccc92fc07e9105.tar.gz
ideviceinstaller-25103d3343074b61c6e2311324ccc92fc07e9105.tar.bz2
Fix long arguments segfaulting due to wrong getopt struct setup
-rw-r--r--src/ideviceinstaller.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ideviceinstaller.c b/src/ideviceinstaller.c
index c8bc239..6187c97 100644
--- a/src/ideviceinstaller.c
+++ b/src/ideviceinstaller.c
@@ -228,16 +228,16 @@ static void parse_opts(int argc, char **argv)
{
static struct option longopts[] = {
{"help", 0, NULL, 'h'},
- {"uuid", 0, NULL, 'U'},
+ {"uuid", 1, NULL, 'U'},
{"list-apps", 0, NULL, 'l'},
- {"install", 0, NULL, 'i'},
- {"uninstall", 0, NULL, 'u'},
- {"upgrade", 0, NULL, 'g'},
+ {"install", 1, NULL, 'i'},
+ {"uninstall", 1, NULL, 'u'},
+ {"upgrade", 1, NULL, 'g'},
{"list-archives", 0, NULL, 'L'},
- {"archive", 0, NULL, 'a'},
- {"restore", 0, NULL, 'r'},
- {"remove-archive", 0, NULL, 'R'},
- {"options", 0, NULL, 'o'},
+ {"archive", 1, NULL, 'a'},
+ {"restore", 1, NULL, 'r'},
+ {"remove-archive", 1, NULL, 'R'},
+ {"options", 1, NULL, 'o'},
{"debug", 0, NULL, 'D'},
{NULL, 0, NULL, 0}
};