[cig-commits] commit 2397 by bangerth to /var/svn/dealii/aspect
dealii.demon at gmail.com
dealii.demon at gmail.com
Wed Apr 2 06:14:58 PDT 2014
Revision 2397
Fix a segmentation fault.
U trunk/aspect/source/velocity_boundary_conditions/gplates.cc
http://www.dealii.org/websvn/revision.php?repname=Aspect+Repository&path=%2F&rev=2397&peg=2397
Diff:
Modified: trunk/aspect/source/velocity_boundary_conditions/gplates.cc
===================================================================
--- trunk/aspect/source/velocity_boundary_conditions/gplates.cc 2014-04-01 16:00:41 UTC (rev 2396)
+++ trunk/aspect/source/velocity_boundary_conditions/gplates.cc 2014-04-02 13:14:54 UTC (rev 2397)
@@ -722,6 +722,14 @@
void
GPlates<dim>::parse_parameters (ParameterHandler &prm)
{
+ // Query the unit system for time since we may have to convert below.
+ // Note that we can't use this->convert_output_to_years() since this
+ // requires the SimulatorAccess base object to have been initialized,
+ // but this hasn't happened yet when we get into this function.
+ const bool
+ use_years_instead_of_seconds
+ = prm.get_bool ("Use years in output instead of seconds");
+
prm.enter_subsection("Boundary velocity model");
{
prm.enter_subsection("GPlates model");
@@ -746,7 +754,7 @@
time_step = prm.get_double ("Time step");
velocity_file_start_time = prm.get_double ("Velocity file start time");
- if (this->convert_output_to_years())
+ if (use_years_instead_of_seconds == true)
{
time_step *= year_in_seconds;
velocity_file_start_time *= year_in_seconds;
More information about the CIG-COMMITS
mailing list