diff --git a/src/cint2c2e.c b/src/cint2c2e.c index 12915c3..efcecc5 100644 --- a/src/cint2c2e.c +++ b/src/cint2c2e.c @@ -80,9 +80,9 @@ non0ctr[it][im], non0idx[it]+im*x_ctr[it]); \ empty_overall = 0; \ } else if (fp2c[i] == CINTiprim_to_ctr_0) { \ - double *pout = gctr[it]; \ + double *pout = gctr[SHLTYPi]; \ int k; \ - for (k = 0; k < nf; k++) { \ + for (k = 0; k < ngp[SHLTYPk]; k++) { \ pout[k] = 0.; \ } \ } \ diff --git a/src/cint2e.c b/src/cint2e.c index 337277d..527e058 100644 --- a/src/cint2e.c +++ b/src/cint2e.c @@ -101,9 +101,9 @@ non0ctr[it][im], non0idx[it]+im*x_ctr[it]); \ empty_overall = 0; \ } else if (fp2c[i] == CINTiprim_to_ctr_0) { \ - double *pout = gp2c[i]; \ + double *pout = gctr[SHLTYPi]; \ int k; \ - for (k = 0; k < ngp[1]; k++) { \ + for (k = 0; k < ngp[SHLTYPj]; k++) { \ pout[k] = 0.; \ } \ } \ diff --git a/src/cint3c2e.c b/src/cint3c2e.c index 0d41ad9..5bed51a 100644 --- a/src/cint3c2e.c +++ b/src/cint3c2e.c @@ -79,9 +79,9 @@ non0ctr[it][im], non0idx[it]+im*x_ctr[it]); \ empty_overall = 0; \ } else if (fp2c[i] == CINTiprim_to_ctr_0) { \ - double *pout = gctr[it]; \ + double *pout = gctr[SHLTYPi]; \ int k; \ - for (k = 0; k < nf; k++) { \ + for (k = 0; k < ngp[SHLTYPj]; k++) { \ pout[k] = 0.; \ } \ } \