In the previous patch https://sourceforge.net/p/openbabel/patches/59/ I inadvertedly did not implement a constructor and destructor for a new class. This is now fixed. Another small fix is that the end-of-file is now checked for using the normal file stream function, rather than checking for a string.
New version of the patch that contains the above patch and also a fix in reading CBS-QB3 enthalpies of formation.
After encountering further problems with an input file that could not be read I changed the re-reading logic of the gaussian file (it is read twice with a rewind in between) to use the proper C++ function to clear end-of-file pointers etc. Tested to work on normal and gzipped files.
There was an additional issue with reading electrostatic potentials as well which is fixed. The tokenize function was replace in this case by sscanf that reads in fixed format potential points, because gaussian uses good old fortran 3(f10.6) with no spaces in between.
Finally a segv was fixed that arose due to orbitals being read in differently than the symmetries. An additional check is left in the code where the orbital data is added to the molecule structure, in case there are broken input files.
A further update of the patch that fixes a bug in computing the enthalpy of formation. Now reproduces literature data.