POLY: free the array pointer as well
This commit is contained in:
parent
4d8b6a78e5
commit
30b917b3be
@ -121,7 +121,9 @@ void poly_delete(fmpz_poly_t poly)
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Delete the internal structure of a polynomial
|
* Delete the internal structure of a polynomial
|
||||||
* array which must be NULL terminated.
|
* array which must be NULL terminated. It is expected
|
||||||
|
* that poly_array is not on the stack and was obtained
|
||||||
|
* by a function like ascii_to_poly().
|
||||||
*
|
*
|
||||||
* @param poly_array the polynomial array
|
* @param poly_array the polynomial array
|
||||||
*/
|
*/
|
||||||
@ -134,6 +136,7 @@ void poly_delete_array(fmpz_poly_t **poly_array)
|
|||||||
free(*(poly_array[i]));
|
free(*(poly_array[i]));
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
|
free(poly_array);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user