Menu

#576 CIF read crashes when _geom_bond_distance values start with decimal dot

v10
open
nobody
CIF (4)
5
2016-03-30
2016-03-30
No

Jmol (as of SVN revision 21035) seems to crash when values of _geom_bond_distance CIF tag do not have initial digit (i.e. ".93(2)"), however, such values are valid CIF numbers.

Example of a real CIF file: http://www.crystallography.net/cod/2009633.cif@31976. After adding missing zeros to the values of _geom_bond_distance the file is read correctly.

Related

Bugs: #576

Discussion

  • Bob Hanson

    Bob Hanson - 2016-03-30

    Jmol.___JmolVersion="14.5.4_2016.03.30"

    bug fix: _geom_bond_distance starting with "." halts CIF file reading

    Will appear first as
    http://chemapps.stolaf.edu/jmol/zip/jmol-14.5.4_2016.03.30.zip

    BTW, not that it matters, but is there some particular reason the space
    group information is at the end of the file? That's quite odd.

     
    • Andrius Merkys

      Andrius Merkys - 2016-03-31

      Thanks for the prompt fix!

      As for 2009633.cif, it seems that the symmetry information was derived later and appended to the end of the file. As far as I know, the order of tags in CIFs is not important (as in data hashes of JSON, Perl and PHP), thus such file is perfectly valid, although it's layout seems unusual.

       
      • Bob Hanson

        Bob Hanson - 2016-04-02

        Jmol.___JmolVersion="14.4.4_2016.03.31"
        released

        bug fix: _geom_bond_distance starting with "." halts CIF file reading

        Looking for the latest version? * Download
        Jmol-14.4.4_2016.03.31-binary.zip (61.3 MB)
        https://sourceforge.net/projects/jmol/files/latest/download?source=files*

        On Thu, Mar 31, 2016 at 1:25 AM, Andrius Merkys merkys@users.sf.net wrote:

        Thanks for the prompt fix!

        As for 2009633.cif, it seems that the symmetry information was derived
        later and appended to the end of the file. As far as I know, the order of
        tags in CIFs is not important (as in data hashes of JSON, Perl and PHP),
        thus such file is perfectly valid, although it's layout seems unusual.


        Status: open
        Group: v10
        Labels: CIF
        Created: Wed Mar 30, 2016 01:47 PM UTC by Andrius Merkys
        Last Updated: Wed Mar 30, 2016 01:47 PM UTC
        Owner: nobody

        Jmol (as of SVN revision 21035) seems to crash when values of
        _geom_bond_distance CIF tag do not have initial digit (i.e. ".93(2)"),
        however, such values are valid CIF numbers.

        Example of a real CIF file:
        http://www.crystallography.net/cod/2009633.cif@31976. After adding
        missing zeros to the values of _geom_bond_distance the file is read
        correctly.


        Sent from sourceforge.net because you indicated interest in
        https://sourceforge.net/p/jmol/bugs/576/

        To unsubscribe from further messages, please visit
        https://sourceforge.net/auth/subscriptions/

        --
        Robert M. Hanson
        Larson-Anderson Professor of Chemistry
        Chair, Department of Chemistry
        St. Olaf College
        Northfield, MN
        http://www.stolaf.edu/people/hansonr

        If nature does not answer first what we want,
        it is better to take what answer we get.

        -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900

         

        Related

        Bugs: #576


Log in to post a comment.