dvbv5-scan: Fix the parsing for the timeout parameter
authorMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 17 Jan 2012 10:21:02 +0000 (08:21 -0200)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 17 Jan 2012 16:10:21 +0000 (14:10 -0200)
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
utils/dvb/dvbv5-scan.c

index b63bb253604e3c691b2b419458790f90402631aa..3c214998bf162d091187ead0793a5c3693136941 100644 (file)
@@ -74,7 +74,7 @@ static const struct argp_option options[] = {
        {"old-format",  'O',    NULL,                   0, "uses old transponder/channel format", 0},
        {"zap",         'z',    "file",                 0, "uses zap services file, discarding video/audio pid's", 0},
        {"file-freqs-only", 'F', NULL,                  0, "don't use the other frequencies discovered during scan", 0},
-       {"timeout-multiply", 'T', NULL,                 0, "Multiply scan timeouts by this factor", 0},
+       {"timeout-multiply", 'T', "factor",             0, "Multiply scan timeouts by this factor", 0},
        { 0, 0, 0, 0, 0, 0 }
 };
 
@@ -456,7 +456,7 @@ static error_t parse_opt(int k, char *optarg, struct argp_state *state)
                verbose++;
                break;
        case 'T':
-               args->timeout_multiply++;
+               args->timeout_multiply = strtoul(optarg, NULL, 0);
                break;
        default:
                return ARGP_ERR_UNKNOWN;