Commit b59383d9 authored by Niels Möller's avatar Niels Möller

Explicitly deallocate storage before exit.

parent 2bd9d1b8
2012-09-10 Niels Möller <nisse@lysator.liu.se>
* examples/eratosthenes.c (main): Explicitly deallocate storage
before exit.
* examples/io.c (read_file): Explicitly treat an empty file as an
error. Rearrange loop, check for short fread return value.
......
......@@ -399,5 +399,9 @@ main (int argc, char **argv)
printf("%lu\n", n);
}
}
free(sieve);
free(block);
return EXIT_SUCCESS;
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment