Changes in molecuilder/src/moleculelist.cpp [486aa5:cc9225]
- File:
-
- 1 edited
-
molecuilder/src/moleculelist.cpp (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
molecuilder/src/moleculelist.cpp
r486aa5 rcc9225 311 311 Tesselation *TesselStruct = NULL; 312 312 if ((srcmol == NULL) || (mol == NULL)) { 313 Log() << Verbose(1) << "ERROR:Either fixed or variable molecule is given as NULL." << endl;313 eLog() << Verbose(1) << "Either fixed or variable molecule is given as NULL." << endl; 314 314 return false; 315 315 } … … 319 319 FindNonConvexBorder(mol, TesselStruct, (const LinkedCell *&)LCList, 4., NULL); 320 320 if (TesselStruct == NULL) { 321 Log() << Verbose(1) << "ERROR:Could not tesselate the fixed molecule." << endl;321 eLog() << Verbose(1) << "Could not tesselate the fixed molecule." << endl; 322 322 return false; 323 323 } … … 402 402 input.open(line.c_str()); 403 403 if (input == NULL) { 404 eLog() << Verbose(0) << endl << "Unable to open " << line << ", is the directory correct?" 405 << endl;404 eLog() << Verbose(0) << endl << "Unable to open " << line << ", is the directory correct?" << endl; 405 performCriticalExit(); 406 406 return false; 407 407 } … … 442 442 if (input == NULL) { 443 443 eLog() << Verbose(0) << endl << "Unable to open " << line << ", is the directory correct?" << endl; 444 performCriticalExit(); 444 445 return false; 445 446 } … … 643 644 if (path != NULL) 644 645 strcpy(PathBackup, path); 645 else 646 else { 646 647 eLog() << Verbose(0) << "OutputConfigForListOfFragments: NULL default path obtained from config!" << endl; 648 performCriticalExit(); 649 } 647 650 648 651 // correct periodic … … 757 760 // 4a. create array of molecules to fill 758 761 const int MolCount = Subgraphs->next->Count(); 762 char number[MAXSTRINGSIZE]; 759 763 molecule **molecules = Malloc<molecule *>(MolCount, "config::Load() - **molecules"); 760 764 for (int i=0;i<MolCount;i++) { 761 765 molecules[i] = (molecule*) new molecule(mol->elemente); 762 766 molecules[i]->ActiveFlag = true; 767 strncpy(molecules[i]->name, mol->name, MAXSTRINGSIZE); 768 if (MolCount > 1) { 769 sprintf(number, "-%d", i+1); 770 strncat(molecules[i]->name, number, MAXSTRINGSIZE - strlen(mol->name) - 1); 771 } 772 cout << "MolName is " << molecules[i]->name << endl; 763 773 insert(molecules[i]); 764 774 } … … 797 807 } 798 808 } 799 // 4d. we don't need to redo bonds, as they are connected subgraphs and still maintain edtheir ListOfBonds, but we have to remove them from first..last list809 // 4d. we don't need to redo bonds, as they are connected subgraphs and still maintain their ListOfBonds, but we have to remove them from first..last list 800 810 bond *Binder = mol->first; 801 811 while (mol->first->next != mol->last) {
Note:
See TracChangeset
for help on using the changeset viewer.
