Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Actions/ParserAction/LoadXyzAction.cpp

    red6dd8 ra1e929  
    7878        if (UniqueList.size() != ListAfter.size()) { // only create if new atoms have been parsed
    7979          MoleculeListClass *molecules = World::getInstance().getMolecules();
    80           molecule *mol = World::getInstance().createMolecule();
    81           molecules->insert(mol);
     80          molecule *mol= NULL;
     81          if (molecules->ListOfMolecules.empty()) {
     82            mol = World::getInstance().createMolecule();
     83            molecules->insert(mol);
     84          } else {
     85            mol = *(molecules->ListOfMolecules.begin());
     86          }
    8287          for (vector<atom *>::iterator runner = ListAfter.begin(); runner != ListAfter.end(); ++runner) {
    8388            Inserter = UniqueList.insert(*runner);
Note: See TracChangeset for help on using the changeset viewer.