Add destroy_global_config. Call it on shutdown
This is for symmetry with init_global_config.
diff --git a/libltrace.c b/libltrace.c
index b69a0c9..54eacb2 100644
--- a/libltrace.c
+++ b/libltrace.c
@@ -91,6 +91,7 @@
{
if (options.summary) {
show_summary();
+ destroy_global_config();
}
if (options.output) {
fclose(options.output);
diff --git a/read_config_file.c b/read_config_file.c
index 53a1891..37ee490 100644
--- a/read_config_file.c
+++ b/read_config_file.c
@@ -1290,7 +1290,13 @@
}
void
-read_config_file(char *file) {
+destroy_global_config(void)
+{
+}
+
+void
+read_config_file(char *file)
+{
FILE *stream;
char buf[1024];
diff --git a/read_config_file.h b/read_config_file.h
index 7c60253..e3cf5cc 100644
--- a/read_config_file.h
+++ b/read_config_file.h
@@ -19,5 +19,6 @@
* 02110-1301 USA
*/
-extern void read_config_file(char *);
-extern void init_global_config(void);
+void read_config_file(char *);
+void init_global_config(void);
+void destroy_global_config(void);