Skip to content

Commit 7238c74

Browse files
committed
preserve potentialargs pointer location before passing to mass function
1 parent 84da14b commit 7238c74

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

galpy/potential/potential_c_ext/PowerSphericalPotentialwCutoff.c

+3-3
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ double PowerSphericalPotentialwCutoffPlanarR2deriv(double R,double phi,
7272
struct potentialArg * potentialArgs){
7373
double * args= potentialArgs->args;
7474
//Get args
75-
double amp= *args++;
76-
double alpha= *args++;
77-
double rc= *args;
75+
double amp= *args;
76+
double alpha= *(args + 1);
77+
double rc= *(args + 2);
7878
//Radius
7979
double r2= R*R;
8080
//Calculate R2deriv

0 commit comments

Comments
 (0)