Skip to content

Commit

Permalink
Fixes test suite (unit-test-client): copy&paste bug, ctx instead of i…
Browse files Browse the repository at this point in the history
…nvalid_ctx (closes stephane#791)
  • Loading branch information
ghorwin committed Jan 20, 2025
1 parent bb13443 commit 0c6b74e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/unit-test-client.c
Original file line number Diff line number Diff line change
Expand Up @@ -673,7 +673,7 @@ int main(int argc, char *argv[])

// Invalid in TCP or RTU mode...
modbus_t *invalid_ctx = modbus_new_tcp("1.2.3.4", 1502);
modbus_set_response_timeout(ctx, 0, 1);
modbus_set_response_timeout(invalid_ctx, 0, 1);
rc = modbus_connect(invalid_ctx);
printf("8/8 Connection timeout: ");
ASSERT_TRUE(rc == -1 && errno == ETIMEDOUT, "");
Expand Down

0 comments on commit 0c6b74e

Please sign in to comment.