From: Fernando Tarlá Cardoso Lemos Date: Fri, 29 Jun 2012 13:30:39 +0000 (-0300) Subject: getopt_long returns int, don't cast to char. X-Git-Tag: 2.5~20 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=65795be0a9a0cafaecd69229244693c0d77984d5;p=i3%2Fi3lock getopt_long returns int, don't cast to char. On ARM, casting -1 to char turns it into something else. Fixes argument parsing on ARM. Thanks Chipaca for reporting. --- diff --git a/i3lock.c b/i3lock.c index 285c1cf..35eaca6 100644 --- a/i3lock.c +++ b/i3lock.c @@ -550,7 +550,7 @@ int main(int argc, char *argv[]) { struct pam_conv conv = {conv_callback, NULL}; int nscreen; int curs_choice = CURS_NONE; - char o; + int o; int optind = 0; struct option longopts[] = { {"version", no_argument, NULL, 'v'},