From 58970d8d7dbc44b2e479f2e61e662dcf8e323526 Mon Sep 17 00:00:00 2001 From: tlatorre Date: Tue, 16 Jul 2019 11:33:51 -0500 Subject: fix bug introduced in ebe2799 This commit fixes a bug introduced in a previous commit when I moved all the code to add the run, gtid, etc. to the event object to get_event(). We actually need the run number before then to load the DQXX file for the right run. --- src/fit.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/fit.c') diff --git a/src/fit.c b/src/fit.c index b0b3318..bdbb7e9 100644 --- a/src/fit.c +++ b/src/fit.c @@ -6163,10 +6163,10 @@ skip_mc: if (gtid > 0 && ev.gtid != gtid) goto skip_event; - if (ev.run != last_run) { - printf("loading DQXX file for run %010i\n", ev.run); + if (bev.run != last_run) { + printf("loading DQXX file for run %010i\n", bev.run); - sprintf(dqxx_file, "DQXX_%010i.dat", ev.run); + sprintf(dqxx_file, "DQXX_%010i.dat", bev.run); if (load_file(db, dqxx_file, 1)) { fprintf(stderr, "failed to load %s: %s\n", dqxx_file, db_err); goto err; @@ -6177,7 +6177,7 @@ skip_mc: goto err; } - last_run = ev.run; + last_run = bev.run; } if (get_event(f,&ev,&b)) goto skip_event; -- cgit