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

HD bug fix: prevent array index out-of-bound error in HDOut_MapOutputs when more than 9 potential-flow bodies are present #2397

Merged
merged 1 commit into from
Aug 29, 2024

Conversation

luwang00
Copy link
Contributor

This pull request is ready to be merged.

Feature or improvement description
Currently, HydroDyn allows an arbitrary number of potential-flow bodies, but the relevant output channels are only available for the first 9 bodies. Having more than 9 bodies in HydroDyn will lead to a memory access exception during output.

This pull request fixes this bug. Output is still limited to the first 9 bodies, but having more potential-flow bodies in the model should no longer cause problems.

Impacted areas of the software
HydroDyn

Test results, if applicable
No change to existing tests since none involve more than 9 potential-flow bodies in HydroDyn.

…s when more than 9 potential-flow bodies are present
Copy link
Collaborator

@jjonkman jjonkman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for finding and fixing this bug!

FYI: This bug was originally reported in: https://forums.nrel.gov/t/hydrodyn-nbody-maximum-limit/7418.

@andrew-platt andrew-platt merged commit cca59dc into OpenFAST:rc-3.5.4 Aug 29, 2024
19 checks passed
@luwang00 luwang00 deleted the b/HD_PFBdy_Output branch August 30, 2024 15:15
@andrew-platt andrew-platt mentioned this pull request Oct 24, 2024
28 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants