Skip to content

Commit fd3e634

Browse files
authored
Merge pull request #197 from gastineau/fix_realloc_cast
add a cast on the returned value of realloc
2 parents 0da66a9 + ba8c0e0 commit fd3e634

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/neogb/modular.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ static inline void generate_lucky_primes(
100100

101101
lp->old = lp->ld;
102102
lp->ld += nr_new_primes;
103-
lp->p = realloc(lp->p, (unsigned long)(lp->ld) * sizeof(uint32_t));
103+
lp->p = (uint32_t *)realloc(lp->p, (unsigned long)(lp->ld) * sizeof(uint32_t));
104104

105105
mpz_t last_prime;
106106
mpz_init(last_prime);

0 commit comments

Comments
 (0)