On Fri Sep 6 17:48:15 2024 +0000, Alex Henrie wrote:
Never mind, I see what you did: On Linux, you defined the `TCPS_` constants yourself with the correct values for Linux. That should be fine, although the comment here is a bit misleading. I wonder if it would be more clear to make the translation from Linux names to BSD names more explicit, for example: ```c #ifndef HAVE_NETINET_TCP_FSM_H #define TCPS_ESTABLISHED TCP_ESTABLISHED #define TCPS_SYN_SENT TCP_SYN_SENT #define TCPS_SYN_RECEIVED TCP_SYN_RECV #define TCPS_FIN_WAIT_1 TCP_FIN_WAIT1 #define TCPS_FIN_WAIT_2 TCP_FIN_WAIT2 #define TCPS_TIME_WAIT TCP_TIME_WAIT #define TCPS_CLOSED TCP_CLOSE #define TCPS_CLOSE_WAIT TCP_CLOSE_WAIT #define TCPS_LAST_ACK TCP_LAST_ACK #define TCPS_LISTEN TCP_LISTEN #define TCPS_CLOSING TCP_CLOSING #endif ``` I just pulled those defines directly from the code I replaced in nsiproxy. I agree that an explicit translation and a comment about what's going on makes more sense. Those constants seem to be exposed in `netinet/tcp.h` on Linux. That feels like territory for another MR to me, after this one is merged.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/6399#note_81419