Commit 20f5e250 authored by Steve Langasek's avatar Steve Langasek Committed by Guillaume Melquiond

Fix unportable assumptions in getopt_long() handling (fixes issue #103).

Don't store an int in a char and expect comparison to -1 to work across
architectures.
parent 5c163f82
......@@ -30,7 +30,7 @@ void parse_options(int argc, char **argv) {
};
while (1) {
int option_index = 0;
char c = 0;
int c = 0;
c = getopt_long (argc, argv, "j:s:",
long_options, &option_index);
/* Detect the end of the options. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment