Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • molecuilder/src/config.cpp

    r486aa5 ra68d44  
    7272  file= new ifstream(filename);
    7373  if (file == NULL) {
    74     eLog() << Verbose(0) << "ERROR: config file " << filename << " missing!" << endl;
     74    eLog() << Verbose(1) << "config file " << filename << " missing!" << endl;
    7575    return;
    7676  }
     
    8787  // allocate buffer's 1st dimension
    8888  if (buffer != NULL) {
    89     eLog() << Verbose(0) << "ERROR: FileBuffer->buffer is not NULL!" << endl;
     89    eLog() << Verbose(1) << "FileBuffer->buffer is not NULL!" << endl;
    9090    return;
    9191  } else
     
    143143  if (LineMapping == NULL) {
    144144    eLog() << Verbose(0) << "map pointer is NULL: " << LineMapping << endl;
     145    performCriticalExit();
    145146    return;
    146147  }
     
    156157    if (CurrentLine+nr < NoLines)
    157158      LineMapping[CurrentLine+(nr++)] = runner->second;
    158     else
     159    else {
    159160      eLog() << Verbose(0) << "config::MapIonTypesInBuffer - NoAtoms is wrong: We are past the end of the file!" << endl;
     161      performCriticalExit();
     162    }
    160163  }
    161164}
     
    653656{
    654657  if (FileBuffer != NULL) {
    655     eLog() << Verbose(1) << "WARNING: deleting present FileBuffer in PrepareFileBuffer()." << endl;
     658    eLog() << Verbose(2) << "deleting present FileBuffer in PrepareFileBuffer()." << endl;
    656659    delete(FileBuffer);
    657660  }
     
    686689  if (MaxTypes == 0) {
    687690    eLog() << Verbose(0) << "There are no atoms according to MaxTypes in this config file." << endl;
     691    performCriticalExit();
    688692  } else {
    689693    // prescan number of ions per type
     
    704708    if (!ParseForParameter(verbose,FileBuffer, (const char*)name, 1, 1, 1, int_type, &value[0], 1, critical)) {
    705709      eLog() << Verbose(0) << "There are no atoms in the config file!" << endl;
     710      performCriticalExit();
    706711      return;
    707712    }
     
    847852  ifstream *file = new ifstream(filename);
    848853  if (file == NULL) {
    849     eLog() << Verbose(0) << "ERROR: config file " << filename << " missing!" << endl;
     854    eLog() << Verbose(1) << "config file " << filename << " missing!" << endl;
    850855    return;
    851856  }
     
    10511056
    10521057  // 2. parse the bond graph file if given
    1053   BG = new BondGraph(IsAngstroem);
    1054   if (BG->LoadBondLengthTable(BondGraphFileName)) {
    1055     Log() << Verbose(0) << "Bond length table loaded successfully." << endl;
    1056   } else {
    1057     Log() << Verbose(0) << "Bond length table loading failed." << endl;
     1058  if (BG == NULL) {
     1059    BG = new BondGraph(IsAngstroem);
     1060    if (BG->LoadBondLengthTable(BondGraphFileName)) {
     1061      Log() << Verbose(0) << "Bond length table loaded successfully." << endl;
     1062    } else {
     1063      eLog() << Verbose(1) << "Bond length table loading failed." << endl;
     1064    }
    10581065  }
    10591066
    10601067  // 3. parse the molecule in
    10611068  LoadMolecule(mol, FileBuffer, periode, FastParsing);
     1069  mol->SetNameFromFilename(filename);
    10621070  mol->ActiveFlag = true;
     1071  MolList->insert(mol);
    10631072
    10641073  // 4. dissect the molecule into connected subgraphs
    1065   MolList->DissectMoleculeIntoConnectedSubgraphs(mol,this);
     1074  // don't do this here ...
     1075  //MolList->DissectMoleculeIntoConnectedSubgraphs(mol,this);
    10661076
    10671077  delete(mol);
     
    10801090  ifstream *file = new ifstream(filename);
    10811091  if (file == NULL) {
    1082     eLog() << Verbose(0) << "ERROR: config file " << filename << " missing!" << endl;
     1092    eLog() << Verbose(1) << "config file " << filename << " missing!" << endl;
    10831093    return;
    10841094  }
Note: See TracChangeset for help on using the changeset viewer.