]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
core.5: Close opened file in example program
authorRahul Bedarkar <rahulbedarkar89@gmail.com>
Sat, 2 Aug 2014 10:02:57 +0000 (15:32 +0530)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Sun, 17 Aug 2014 15:30:37 +0000 (10:30 -0500)
Signed-off-by: Rahul Bedarkar <rahulbedarkar89@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man5/core.5

index 074add6e49deeebd2be13112be3c31f00fb96493..f2c3e36aedf3f7f2b9fcf9d2a1588e99cba7ef7b 100644 (file)
@@ -422,6 +422,7 @@ main(int argc, char *argv[])
         tot += nread;
     fprintf(fp, "Total bytes in core dump: %d\\n", tot);
 
+    fclose(fp);
     exit(EXIT_SUCCESS);
 }
 .fi