printf(" -%c, --%s%c\n", long_options[x].val, long_options[x].name,
long_options[x].has_arg ? '=' : ' ');
printf(" -%c, --%s%c\n", long_options[x].val, long_options[x].name,
long_options[x].has_arg ? '=' : ' ');
optarg[strlen(optarg) - 1] = '\0';
errno = 0;
ret = strtoll(optarg, (char **) NULL, 10);
optarg[strlen(optarg) - 1] = '\0';
errno = 0;
ret = strtoll(optarg, (char **) NULL, 10);
fprintf(stderr, "strtoll(optarg,..): %s\n", strerror(errno));
exit(1);
}
fprintf(stderr, "strtoll(optarg,..): %s\n", strerror(errno));
exit(1);
}
case OPT_CONCURRENCY: /* --concurrency or -c */
errno = 0;
ms_setting.nconns = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_CONCURRENCY: /* --concurrency or -c */
errno = 0;
ms_setting.nconns = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_EXECUTE_NUMBER: /* --execute_number or -x */
errno = 0;
ms_setting.exec_num = (int) strtol(optarg, (char **) NULL, 10);
case OPT_EXECUTE_NUMBER: /* --execute_number or -x */
errno = 0;
ms_setting.exec_num = (int) strtol(optarg, (char **) NULL, 10);
case OPT_THREAD_NUMBER: /* --threads or -T */
errno = 0;
ms_setting.nthreads = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_THREAD_NUMBER: /* --threads or -T */
errno = 0;
ms_setting.nthreads = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_FIXED_LTH: /* --fixed_size or -X */
errno = 0;
ms_setting.fixed_value_size = (size_t) strtoull(optarg, (char **) NULL, 10);
case OPT_FIXED_LTH: /* --fixed_size or -X */
errno = 0;
ms_setting.fixed_value_size = (size_t) strtoull(optarg, (char **) NULL, 10);
|| (ms_setting.fixed_value_size > MAX_VALUE_SIZE))
{
fprintf(stderr, "Value size must be between 0 and 1M.:-)\n");
|| (ms_setting.fixed_value_size > MAX_VALUE_SIZE))
{
fprintf(stderr, "Value size must be between 0 and 1M.:-)\n");
case OPT_GETS_DIVISION: /* --division or -d */
errno = 0;
ms_setting.mult_key_num = (int) strtol(optarg, (char **) NULL, 10);
case OPT_GETS_DIVISION: /* --division or -d */
errno = 0;
ms_setting.mult_key_num = (int) strtol(optarg, (char **) NULL, 10);
case OPT_SOCK_PER_CONN: /* --conn_sock or -n */
errno = 0;
ms_setting.sock_per_conn = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_SOCK_PER_CONN: /* --conn_sock or -n */
errno = 0;
ms_setting.sock_per_conn = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_REP_WRITE_SRV: /* --rep_write or -p */
errno = 0;
ms_setting.rep_write_srv = (uint32_t) strtoul(optarg, (char **) NULL, 10);
case OPT_REP_WRITE_SRV: /* --rep_write or -p */
errno = 0;
ms_setting.rep_write_srv = (uint32_t) strtoul(optarg, (char **) NULL, 10);