Skip to content

Commit

Permalink
change getopt return from char to int
Browse files Browse the repository at this point in the history
  • Loading branch information
MaZderMind committed Apr 2, 2013
1 parent 2e2dde1 commit 44a25ab
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion audio_ao.c
Expand Up @@ -49,7 +49,8 @@ static int init(int argc, char **argv) {

optind = 0;
// some platforms apparently require optreset = 1; - which?
char opt, *mid;
int opt;
char *mid;
while ((opt = getopt(argc, argv, "d:i:n:o:")) > 0) {
switch (opt) {
case 'd':
Expand Down
2 changes: 1 addition & 1 deletion shairport.c
Expand Up @@ -73,7 +73,7 @@ void usage(char *progname) {
}

int parse_options(int argc, char **argv) {
char opt;
int opt;
while ((opt = getopt(argc, argv, "+hvp:a:o:b:")) > 0) {
switch (opt) {
default:
Expand Down

0 comments on commit 44a25ab

Please sign in to comment.