uWebSockets icon indicating copy to clipboard operation
uWebSockets copied to clipboard

Fix compilation error in HttpServer example

Open alastairpatrick opened this issue 5 years ago • 2 comments

alastairpatrick avatar Dec 06 '20 21:12 alastairpatrick

Tangentially related, for a future pull request, not this one, what do you think of something like this:

struct SocketContextOptions : us_socket_context_options_t {
    SocketContextOptions() : us_socket_context_options_t({}) {
    }
};

The idea is that the member variables would all be initialized to default values without the need to be kept in sync between two structs and there would be no need for a conversion operator since SocketContextOptions would inherit from us_socket_context_options_t.

alastairpatrick avatar Dec 07 '20 07:12 alastairpatrick

Yes SocketContextOptions was added very recently to fix a warning, it can be improved

ghost avatar Dec 14 '20 18:12 ghost