This commit is contained in:
Kartik K. Agaram 2017-12-05 01:09:19 -08:00
parent a87118d989
commit 26b4bdc8b3
4 changed files with 5 additions and 5 deletions

View File

@ -215,7 +215,7 @@ lease_tracer::lease_tracer() { Trace_stream = new trace_stream; }
lease_tracer::~lease_tracer() {
if (!Trace_stream) return; // in case tests close Trace_stream
if (Save_trace) {
ofstream fout("last_trace");
ofstream fout("last_run");
fout << Trace_stream->readable_contents("");
fout.close();
}

View File

@ -180,7 +180,7 @@ case _SAVE_TRACE: {
:(before "End Primitive Recipe Implementations")
case _SAVE_TRACE: {
if (Save_trace) {
ofstream fout("last_trace");
ofstream fout("last_run");
fout << Trace_stream->readable_contents("");
fout.close();
}

View File

@ -76,8 +76,8 @@ void decrement_refcount(int old_address, const type_tree* payload_type, int payl
if (old_refcount < 0) {
cerr << "Negative refcount!!! " << old_address << ' ' << old_refcount << '\n';
if (Trace_stream) {
cerr << "Saving trace to last_trace.\n";
ofstream fout("last_trace");
cerr << "Saving trace to last_run.\n";
ofstream fout("last_run");
fout << Trace_stream->readable_contents("");
fout.close();
}

View File

@ -230,7 +230,7 @@ void run_mu_scenario(const scenario& s) {
Passed = false;
if (not_already_inside_test && Trace_stream) {
if (Save_trace) {
ofstream fout("last_trace");
ofstream fout("last_run");
fout << Trace_stream->readable_contents("");
fout.close();
}