From 464d16cc69511038d2c96f25ce27ce5537a40f8e Mon Sep 17 00:00:00 2001 From: Xavier Robin <xavier.robin@unibas.ch> Date: Fri, 12 Jul 2024 11:01:02 +0200 Subject: [PATCH] fix: info level logging displays the correct data All counts were reset to 0 by a call to NextMolecule(). Now we are displaying the data straight from the entity. Assumes an empty entity at the start. --- modules/io/src/mol/sdf_reader.cc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/io/src/mol/sdf_reader.cc b/modules/io/src/mol/sdf_reader.cc index 76c7091a2..70ee382b1 100644 --- a/modules/io/src/mol/sdf_reader.cc +++ b/modules/io/src/mol/sdf_reader.cc @@ -113,9 +113,11 @@ void SDFReader::Import(mol::EntityHandle& ent) ProcessV3000Line(line, ent, editor); } } - - LOG_INFO("imported " << chain_count_ << " chains, " << residue_count_ - << " residues, " << atom_count_ << " atoms"); + LOG_INFO("imported " + << ent.GetChainCount() << " chains, " + << ent.GetResidueCount() << " residues, " + << ent.GetAtomCount() << " atoms and " + << ent.GetBondCount() << " bonds"); } void SDFReader::ClearState(const boost::filesystem::path& loc) -- GitLab