Skip to content

Commit

Permalink
修复windows下编译错误
Browse files Browse the repository at this point in the history
  • Loading branch information
HEYAHONG committed Sep 21, 2024
1 parent 6b98ddf commit 1a527d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/ModbusTCPServerTiny/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ static void server_thread()
struct timeval tv;
tv.tv_sec = 0;
tv.tv_usec = 5*1000;
setsockopt(connection_fd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv));
setsockopt(connection_fd, SOL_SOCKET, SO_RCVTIMEO, (const char *)&tv, sizeof(tv));
}
bool is_running=true;
while(is_running)
Expand Down

0 comments on commit 1a527d1

Please sign in to comment.