You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In MQTT-SN Stack asynCute, some mutex_unlock() calls are missing, which I could easily change.
These mutex_unlock() calls are mostly missing where an error is queried that should not occur in normal operation. In addition to the mutex_unlock() command, the central callback function con->cb() should also be called by inserting a new error state so that the system can be restarted, for example. The latter would cause compatibility problems with existing implementations. Alternatively, this could also be solved with assert(), but this would not be my preferred solution.
How should I deal with the call to the callback function, which I believe is missing? I would be happy to initially incorporate these calls as a comment in the code.
Steps to reproduce the issue
Only proven in a theoretical context
Expected results
In the event of an error, no further use of asymcute_req_t objects is possible.
Error query caused, for example, by incorrect dereferencing, so that the system state is to be regarded as critical.
Actual results
Versions
The text was updated successfully, but these errors were encountered:
Could you be more specific where exactly the calls to mutex_unlock are missing? The most straightforward way would be for you to change the file accordingly and propose a PR for us to review the changes.
The missing call to the callback function sounds to me like a separate problem that could be fixed in a second PR. Without having a closer look at the implementation, it sounds reasonable to me to somehow stop the module when an error occurs, and passing it through the callback function sounds reasonable too.
Description
In MQTT-SN Stack asynCute, some mutex_unlock() calls are missing, which I could easily change.
These mutex_unlock() calls are mostly missing where an error is queried that should not occur in normal operation. In addition to the mutex_unlock() command, the central callback function con->cb() should also be called by inserting a new error state so that the system can be restarted, for example. The latter would cause compatibility problems with existing implementations. Alternatively, this could also be solved with assert(), but this would not be my preferred solution.
How should I deal with the call to the callback function, which I believe is missing? I would be happy to initially incorporate these calls as a comment in the code.
Steps to reproduce the issue
Only proven in a theoretical context
Expected results
In the event of an error, no further use of asymcute_req_t objects is possible.
Error query caused, for example, by incorrect dereferencing, so that the system state is to be regarded as critical.
Actual results
Versions
The text was updated successfully, but these errors were encountered: