Hi,

I was trying to use obprop on an SDF file, but found out that it adds one hydrogen to my compound that should not be there. I then went to look at the code and removed these two lines
      if (!mol.HasHydrogensAdded())
        mol.AddHydrogens();
recompiled and installed.
Lo and behold, the bug is still there! That is, upon reading an SDF file the library already adds a hydrogen that shouldn't be there.

What to do about this?
Replace
      conv.Read(&mol, &ifs);
by a new call
      conv.ReadAndDoNotModifyMyCompound(&mol, &ifs);

Other suggestions?

--
David van der Spoel, Ph.D., Professor of Biology
Head of Department, Cell & Molecular Biology, Uppsala University.
Box 596, SE-75124 Uppsala, Sweden. Phone: +46184714205.
http://www.icm.uu.se


_______________________________________________
OpenBabel-Devel mailing list
OpenBabel-Devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-devel

Reply via email to