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

ConfigRawParams: fix typecast exception #3094

Merged

Conversation

robertlong13
Copy link
Collaborator

When editing a float param, the cell gets set to a double, instead of a string, which throws a typecase exception if the cell is edited and then "None Default" is clicked. I fix this on both ends, setting the cell to a string, and using ToString everywhere instead of typecasting.

The only part of this PR that is truly needed is the ToString on line 446, but it's too easy to make a similar mistake in the future and have it go unnoticed.

When editing a float param, the cell gets set to a double, instead of a
string, which throws a typecase exception if the cell is edited and
then "None Default" is clicked. I fix this on both ends, setting the
cell to a string, and using ToString everywhere instead of typecasting.
@meee1 meee1 merged commit 0ad6616 into ArduPilot:master Apr 26, 2023
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.

2 participants