Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#1303. Change the inject_tlm to directly modify the CVT packet object #1304

Closed

Conversation

mikemattball
Copy link

This changes the inject_tlm method to directly modify the CVT packet object instead of cloning. This makes it so it is maintaining the limits status in the CVT object as well as any other state information that is lost with the previous cloning method.

@mikemattball mikemattball changed the title 1303. Change the inject_tlm to directly modify the CVT packet object #1303. Change the inject_tlm to directly modify the CVT packet object Jun 30, 2021
@mikemattball
Copy link
Author

I was thinking more about this code last night. I think there could be a race condition because this inject_tlm is potentially happening in parallel with the interface_thread incoming telemetry. I'm guessing that's why the object was cloned, and why there was a note about possible confusion with checking the limits in the inject_tlm. I think the proper fix would be to mutex protect the object in both locations so only one could modify the object at a time.

@ghost
Copy link

ghost commented Sep 21, 2021

Fixed in #1363

@ghost ghost closed this Sep 21, 2021
@ghost ghost added this to the v4.5.1 milestone Sep 21, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant