Never mind ... problem solved. In the course of putting a complete
example, I discovered that my Makefile had
-I/usr/local/openbabel/lib/openbabel-2.0
which points to the OpenBabel 2.2.x code. In fact I was linking against a
new version of OpenBabel 2.3.x, so the include files didn't match th
On Mon, May 7, 2012 at 10:09 AM, Geoffrey Hutchison wrote:
>
> On May 4, 2012, at 10:45 PM, Craig James wrote:
>
> > But it seems to be the atom iterator, not the ring iterator, that's
> causing the problem.
>
> Huh. Here's comparable code in forcefieldmmff94.cpp:
>
> for(rj = (*ri)->_path.b
On May 4, 2012, at 10:45 PM, Craig James wrote:
> But it seems to be the atom iterator, not the ring iterator, that's causing
> the problem.
Huh. Here's comparable code in forcefieldmmff94.cpp:
for(rj = (*ri)->_path.begin();rj != (*ri)->_path.end();rj++) { // for
each ring atom
On Fri, May 4, 2012 at 6:03 PM, Igor Filippov wrote:
>
> I would get rlist quite the same way. This is what I have - no crashes,
> though I don't iterate over the atoms quite like you do:
>
> vector vr = mol.GetSSSR();
>
> for (vector::iterator iter = vr.begin(); iter != vr.end();
> iter++)
>
> From:
> Igor Filippov
>
>To:
> Craig James
>Cc:
> openbabel-devel@lists.sourceforge.net
> Subject:
> Re: [OpenBabel-Deve
I would get rlist quite the same way. This is what I have - no crashes,
though I don't iterate over the atoms quite like you do:
vector vr = mol.GetSSSR();
for (vector::iterator iter = vr.begin(); iter != vr.end();
iter++)
{
num_rings++;
if ((*iter)->IsAromatic())
num
Can anyone tell me why this code crashes? It's copied almost verbatim from
the OpenBabel OBRing API page.
Note: I wasn't sure if the "mol->GetSSSR()" call was needed before calling
mol->GetData("RingList"), so I added it to be sure. The man page wasn't
clear about this.
Thanks,
Craig
mol->Ge