parent
588bc7b7f9
commit
de5c62a901
|
|
@ -26,7 +26,7 @@ main(int argc, char **argv)
|
|||
double x, *table;
|
||||
int i, n;
|
||||
|
||||
table = calloc(sizeof(double), TABLESIZE);
|
||||
table = calloc(sizeof(double), TABLESIZE+1);
|
||||
if (!table) {
|
||||
fprintf(stderr, "Not enough memory\n");
|
||||
return 1;
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ main(int argc, char **argv)
|
|||
double *table;
|
||||
int i,n;
|
||||
|
||||
table = calloc(TABLESIZE, sizeof(double));
|
||||
table = calloc(TABLESIZE+1, sizeof(double));
|
||||
if (!table) {
|
||||
fprintf(stderr, "Out of memory!\n");
|
||||
exit(1);
|
||||
|
|
|
|||
Loading…
Reference in New Issue