Skip to content

Commit

Permalink
Fixed optarg processing in peer discovery client
Browse files Browse the repository at this point in the history
Signed-off-by: leonard.kosta <[email protected]>
  • Loading branch information
kostaleonard committed Jan 4, 2025
1 parent 334c602 commit e9b418f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/peer_discovery_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ void print_usage_statement(char *program_name) {

int main(int argc, char **argv) {
return_code_t return_code = SUCCESS;
size_t num_positional_args = 3;
if (argc < num_positional_args) {
size_t num_positional_args = 2;
if (argc < num_positional_args + 1) {
print_usage_statement(argv[0]);
return_code = FAILURE_INVALID_COMMAND_LINE_ARGS;
goto end;
Expand Down

0 comments on commit e9b418f

Please sign in to comment.