Skip to content

Commit

Permalink
fix n
Browse files Browse the repository at this point in the history
  • Loading branch information
bodono committed Jun 28, 2024
1 parent 54e5f42 commit 72b6158
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/problems/test_prob_from_data_file.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ static const char *_test_prob_from_data(const char *file, scs_float OPT) {
if (d->P) {
/* px = Px */
px = (scs_float *)scs_calloc(d->n, sizeof(scs_float));
memset(px, 0, n * sizeof(scs_float));
memset(px, 0, d->n * sizeof(scs_float));
SCS(accum_by_p)(d->P, sol->x, px);
xt_p_x = SCS(dot)(px, sol->x, n);
xt_p_x = SCS(dot)(px, sol->x, d->n);
} else {
xt_p_x = 0.;
}
Expand Down

0 comments on commit 72b6158

Please sign in to comment.