Skip to content
Snippets Groups Projects
Commit 04fa011d authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Make sure gravity (self or external) is switched on when running with stars.

parent 4b2ed413
Branches
Tags
1 merge request!358Make sure gravity (self or external) is switched on when running with stars.
...@@ -294,6 +294,14 @@ int main(int argc, char *argv[]) { ...@@ -294,6 +294,14 @@ int main(int argc, char *argv[]) {
if (myrank == 0) print_help_message(); if (myrank == 0) print_help_message();
return 1; return 1;
} }
if (with_stars && !with_external_gravity && !with_self_gravity) {
if (myrank == 0)
printf(
"Error: Cannot run with stars but without gravity, -g or -G must be "
"chosen.\n");
if (myrank == 0) print_help_message();
return 1;
}
/* Genesis 1.1: And then, there was time ! */ /* Genesis 1.1: And then, there was time ! */
clocks_set_cpufreq(cpufreq); clocks_set_cpufreq(cpufreq);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment