aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetLib/src/gdata.cc
diff options
context:
space:
mode:
authorErik Schnetter <schnetter@cct.lsu.edu>2010-04-27 11:58:27 -0500
committerBarry Wardell <barry.wardell@gmail.com>2011-12-14 18:21:08 +0000
commit3059e8bd939a7dcdef4b26874ceeb07406e72e13 (patch)
tree0d2bf02876a2336b80337d6ef98afcaddf45bc1d /Carpet/CarpetLib/src/gdata.cc
parentbfd46b090088e3006978362ab39207d06749313d (diff)
CarpetLib: Output grid variable name in error message
Output grid variable name in find_source_timelevel's error messages.
Diffstat (limited to 'Carpet/CarpetLib/src/gdata.cc')
-rw-r--r--Carpet/CarpetLib/src/gdata.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/Carpet/CarpetLib/src/gdata.cc b/Carpet/CarpetLib/src/gdata.cc
index 1bcc38045..4219b80c3 100644
--- a/Carpet/CarpetLib/src/gdata.cc
+++ b/Carpet/CarpetLib/src/gdata.cc
@@ -294,8 +294,13 @@ find_source_timelevel (vector <CCTK_REAL> const & times,
{
ostringstream buf;
buf << setprecision (17)
- << "Internal error: extrapolation in time."
- << " time=" << time
+ << "Internal error: extrapolation in time.";
+ if (varindex >= 0) {
+ char * const fullname = CCTK_FullName (varindex);
+ buf << " variable=" << fullname;
+ ::free (fullname);
+ }
+ buf << " time=" << time
<< " times=" << times;
CCTK_WARN (0, buf.str().c_str());
}