Skip to content

Commit

Permalink
Arghh... OK, test for factory nullness here once more then :(
Browse files Browse the repository at this point in the history
  • Loading branch information
egonw committed May 20, 2010
1 parent 3a49ae5 commit 1b2a534
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ public void generate( IMolecule molecule,
atom.setFlag(CDKConstants.ISAROMATIC, false);
for (IBond bond : clone.bonds())
bond.setFlag(CDKConstants.ISAROMATIC, false);
// FIXME: this should already have been covered by the earlier
// isAvailable() call, but wasn't... weird...
if (factory == null)
returner.completeReturn(InChI.FAILED_TO_CALCULATE);
InChIGenerator gen = factory.getInChIGenerator(clone);
INCHI_RET status = gen.getReturnStatus();
if(monitor.isCanceled())
Expand Down

0 comments on commit 1b2a534

Please sign in to comment.