From ca162f5a65b3a4d60dc502e808a753f0f4135399 Mon Sep 17 00:00:00 2001 From: Howard Soh Date: Mon, 27 Jun 2022 13:21:58 -0600 Subject: [PATCH] #1815 cleanup --- .../other/mode_graphics/mode_nc_output_file.cc | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/tools/other/mode_graphics/mode_nc_output_file.cc b/src/tools/other/mode_graphics/mode_nc_output_file.cc index b54b9d3601..ce45948a81 100644 --- a/src/tools/other/mode_graphics/mode_nc_output_file.cc +++ b/src/tools/other/mode_graphics/mode_nc_output_file.cc @@ -255,23 +255,17 @@ for (x=0; x init time should be an integer or a string!\n\n"; exit ( 1 ); } - if (att) delete att; - att = get_nc_att(FcstRaw, (string)"valid_time_ut"); - ValidTime = get_att_value_unixtime(att); - if (ValidTime < 0) { + if (!get_att_unixtime(FcstRaw, valid_time_ut_att_name, ValidTime) || ValidTime < 0) { mlog << Error << "ModeNcOutputFile::open(const char *) -> valid time should be an integer or a string!\n\n"; exit ( 1 ); } - if (att) delete att; // att = FcstRaw->get_att("accum_time_sec"); // @@ -1006,6 +1000,3 @@ return ( s ); //////////////////////////////////////////////////////////////////////// - - -