Ticket #88: avahi-invalid_arg.patch

File avahi-invalid_arg.patch, 4.1 KB (added by tedp, 5 years ago)
  • avahi-utils/avahi-resolve.c

     
    186186    c->proto = AVAHI_PROTO_UNSPEC; 
    187187    c->verbose = 0; 
    188188 
    189     opterr = 0; 
    190189    while ((o = getopt_long(argc, argv, "hVnav46", long_options, NULL)) >= 0) { 
    191190 
    192191        switch(o) { 
     
    212211                c->proto = AVAHI_PROTO_INET6; 
    213212                break; 
    214213            default: 
    215                 fprintf(stderr, "Invalid command line argument: %c\n", o); 
    216214                return -1; 
    217215        } 
    218216    } 
  • avahi-utils/avahi-browse.c

     
    638638    c->no_db_lookup = 0; 
    639639#endif 
    640640     
    641     opterr = 0; 
    642641    while ((o = getopt_long(argc, argv, "hVd:avtclrDf" 
    643642#if defined(HAVE_GDBM) || defined(HAVE_DBM) 
    644643                            "k" 
     
    686685                break; 
    687686#endif 
    688687            default: 
    689                 fprintf(stderr, "Invalid command line argument: %c\n", o); 
    690688                return -1; 
    691689        } 
    692690    } 
  • avahi-utils/avahi-set-host-name.c

     
    9393    c->command = COMMAND_UNSPEC; 
    9494    c->verbose = 0; 
    9595 
    96     opterr = 0; 
    9796    while ((o = getopt_long(argc, argv, "hVv", long_options, NULL)) >= 0) { 
    9897 
    9998        switch(o) { 
     
    107106                c->verbose = 1; 
    108107                break; 
    109108            default: 
    110                 fprintf(stderr, "Invalid command line argument: %c\n", o); 
    111109                return -1; 
    112110        } 
    113111    } 
  • avahi-utils/avahi-publish.c

     
    256256    c->port = 0; 
    257257    c->txt = c->subtypes = NULL; 
    258258 
    259     opterr = 0; 
    260259    while ((o = getopt_long(argc, argv, "hVsavd:H:f", long_options, NULL)) >= 0) { 
    261260 
    262261        switch(o) { 
     
    290289                c->subtypes = avahi_string_list_add(c->subtypes, optarg); 
    291290                break; 
    292291            default: 
    293                 fprintf(stderr, "Invalid command line argument: %c\n", o); 
    294292                return -1; 
    295293        } 
    296294    } 
  • avahi-daemon/main.c

     
    379379 
    380380    assert(c); 
    381381 
    382     opterr = 0; 
    383382    while ((o = getopt_long(argc, argv, "hDkVf:rcs", long_options, NULL)) >= 0) { 
    384383 
    385384        switch(o) { 
     
    426425                c->debug = 1; 
    427426                break; 
    428427            default: 
    429                 fprintf(stderr, "Invalid command line argument: %c\n", o); 
    430428                return -1; 
    431429        } 
    432430    } 
  • avahi-autoipd/main.c

     
    12001200        { NULL, 0, NULL, 0 } 
    12011201    }; 
    12021202 
    1203     opterr = 0; 
    12041203    while ((c = getopt_long(argc, argv, "hDskrcVS:w", long_options, NULL)) >= 0) { 
    12051204 
    12061205        switch(c) { 
     
    12591258#endif 
    12601259 
    12611260            default: 
    1262                 fprintf(stderr, "Invalid command line argument: %c\n", c); 
    12631261                return -1; 
    12641262        } 
    12651263    } 
  • avahi-dnsconfd/main.c

     
    396396        { NULL, 0, NULL, 0 } 
    397397    }; 
    398398 
    399     opterr = 0; 
    400399    while ((c = getopt_long(argc, argv, "hDkVrc", long_options, NULL)) >= 0) { 
    401400 
    402401        switch(c) { 
     
    419418                command = DAEMON_CHECK; 
    420419                break; 
    421420            default: 
    422                 fprintf(stderr, "Invalid command line argument: %c\n", c); 
    423421                return -1; 
    424422        } 
    425423    }