@@ -948,8 +948,8 @@ void frolladaptivemedianExact(const double *x, uint64_t nx, ans_t *ans, const in
948948 }
949949 }
950950 } else {
951- int * rollnc = malloc (sizeof (* rollnc ) * nx ); // for frolladaptiveNAExact we need calloc, for frolladaptiveNAFast malloc is ok
952951 //int *rollnc = calloc(nx, sizeof(*rollnc)); // use when frolladaptiveFast will be implemented
952+ int * rollnc = malloc (sizeof (* rollnc ) * nx ); // for frolladaptiveNAExact we need calloc, for frolladaptiveNAFast malloc is ok
953953 if (!rollnc ) { // # nocov start
954954 ansSetMsg (ans , 3 , "%s: Unable to allocate memory for rollnc" , __func__ ); // raise error
955955 free (xx );
@@ -961,8 +961,8 @@ void frolladaptivemedianExact(const double *x, uint64_t nx, ans_t *ans, const in
961961 free (rollnc ); free (xx );
962962 return ;
963963 } // # nocov end
964- int nc = frolladaptiveNAFast (x , nx , k , rollnc , isna );
965964 //int nc = frolladaptiveNAExact(x, nx, k, rollnc, isna); // use when frolladaptiveFast will be implemented
965+ int nc = frolladaptiveNAFast (x , nx , k , rollnc , isna );
966966 if (!nc ) { // total NA for x
967967 if (verbose )
968968 snprintf (end (ans -> message [0 ]), 500 , _ ("%s: no NAs detected, redirecting to itself using has.nf=FALSE\n" ), "frolladaptivemedianExact" );
0 commit comments