aboutsummaryrefslogtreecommitdiff
path: root/src/misc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/misc.c')
-rw-r--r--src/misc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/misc.c b/src/misc.c
index 88e4b77..56760e4 100644
--- a/src/misc.c
+++ b/src/misc.c
@@ -726,7 +726,7 @@ void combinations_with_replacement(size_t n, size_t r, size_t *result, size_t *l
size_t i, j;
size_t *tmp;
- tmp = malloc(sizeof(size_t)*n*ipow(r,n));
+ tmp = malloc(sizeof(size_t)*n*ipow(n,r));
product(n,r,tmp);