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

Control flow issue in subdivide_hydrofabric #825

Open
PhilMiller opened this issue May 29, 2024 · 1 comment
Open

Control flow issue in subdivide_hydrofabric #825

PhilMiller opened this issue May 29, 2024 · 1 comment

Comments

@PhilMiller
Copy link
Contributor

In commit b62389d, the logic of Python availability in subdivide_hydrofabric was changed. This created the situation where a build with MPI enabled and Python disabled would generate the following warning:

In file included from /repos/ngen/src/NGen.cpp:51:
/repos/ngen/include/utilities/parallel_utils.h: In function 'bool parallel::subdivide_hydrofabric(int, int, const string&, const string&, const string&)':
/repos/ngen/include/utilities/parallel_utils.h:536:5: warning: control reaches end of non-void function [-Wreturn-type]

I agree with the warning - in that case, the function can fail to specify its return value, leading to undefined behavior.

@PhilMiller
Copy link
Contributor Author

@robertbartel

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

No branches or pull requests

1 participant