I’m investigating the use of user_data in the mongoose webserver. I noticed that user_data in mg_connection is passed to subsequent calls to the event handler function. I would expect the connection user_data to be separated from the mg_mgr user_data so we can link extra connection data. Is my assumption incorrect?
To replicate this issue: just set the connection user_data to another value in the eventhandler. The next call to the eventhandler will get this user_data passed in, which doesn’t seem correct to me. This way, it is not possible to create a c++ wrapper class around the server.
Kind regards,
Merijn