X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fvm_power_manager%2Fvm_power_cli.c;h=7690d1497d265d6e948b8533649253eba3cd5e10;hb=ab3257e13dc4618bd4fe3d38728c1786095cd3e5;hp=e7f4469170905b44ba9cacaf5a0a4c9e2e919875;hpb=3842bf2424e27d4092fafcab000e10935c5d47f3;p=dpdk.git diff --git a/examples/vm_power_manager/vm_power_cli.c b/examples/vm_power_manager/vm_power_cli.c index e7f4469170..7690d1497d 100644 --- a/examples/vm_power_manager/vm_power_cli.c +++ b/examples/vm_power_manager/vm_power_cli.c @@ -323,7 +323,7 @@ cmd_channels_op_parsed(void *parsed_result, struct cmdline *cl, break; errno = 0; channel_num = (unsigned)strtol(token, &tail_ptr, 10); - if ((errno != 0) || (*tail_ptr != '\0') || tail_ptr == NULL) + if ((errno != 0) || tail_ptr == NULL || (*tail_ptr != '\0')) break; if (channel_num == CHANNEL_CMDS_MAX_VM_CHANNELS) { @@ -408,7 +408,7 @@ cmd_channels_status_op_parsed(void *parsed_result, struct cmdline *cl, break; errno = 0; channel_num = (unsigned)strtol(token, &tail_ptr, 10); - if ((errno != 0) || (*tail_ptr != '\0') || tail_ptr == NULL) + if ((errno != 0) || tail_ptr == NULL || (*tail_ptr != '\0')) break; if (channel_num == CHANNEL_CMDS_MAX_VM_CHANNELS) { @@ -624,7 +624,7 @@ cmd_set_cpu_freq_parsed(void *parsed_result, struct cmdline *cl, cmdline_parse_token_string_t cmd_set_cpu_freq = TOKEN_STRING_INITIALIZER(struct cmd_set_cpu_freq_result, set_cpu_freq, "set_cpu_freq"); -cmdline_parse_token_string_t cmd_set_cpu_freq_core_num = +cmdline_parse_token_num_t cmd_set_cpu_freq_core_num = TOKEN_NUM_INITIALIZER(struct cmd_set_cpu_freq_result, core_num, UINT8); cmdline_parse_token_string_t cmd_set_cpu_freq_cmd_cmd =