equal
deleted
inserted
replaced
42 printf ("Report bugs to mbroeker@largo.homelinux.org\n"); |
42 printf ("Report bugs to mbroeker@largo.homelinux.org\n"); |
43 return EXIT_FAILURE; |
43 return EXIT_FAILURE; |
44 } |
44 } |
45 |
45 |
46 if ((p = malloc (N * size)) == NULL) |
46 if ((p = malloc (N * size)) == NULL) |
47 return EXIT_SUCCESS; |
47 return EXIT_FAILURE; |
48 |
48 |
49 while (1) { |
49 for (;;) { |
50 for (i = 0; i < N; i++) { |
50 for (i = 0; i < N; i++) { |
51 p[n * N + i] = size * (n * N + i); |
51 p[n * N + i] = size * (n * N + i); |
52 } |
52 } |
53 if ((p_new = realloc (p, (++n + 1) * N * size))) |
53 if ((p_new = realloc (p, (++n + 1) * N * size))) |
54 p = p_new; |
54 p = p_new; |