summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authorGravatar Alan Fitton <ajf@eth0.org.uk>2011-09-18 18:01:27 +0000
committerGravatar Alan Fitton <ajf@eth0.org.uk>2011-09-18 18:01:27 +0000
commitfdbfb01d85f49717c3b8928d97bc16c4e7b860d7 (patch)
treec64e1c66f0bf969935997fd0c31a03c05d07fd64 /src/main.c
parenta681a90c2166722fedb52ecbbd4f9c56f97ebcd3 (diff)
changes to make memory profiling easier
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index e64f35c..63e9ca2 100644
--- a/src/main.c
+++ b/src/main.c
@@ -98,6 +98,13 @@ int main(int argc, char *argv[])
TrgMainWindow *window;
TrgClient *client;
+#ifdef DEBUG
+ //GMemVTable gmvt = {malloc,realloc,free,calloc,malloc,realloc};
+ //g_mem_set_vtable(&gmvt);
+ g_mem_set_vtable(glib_mem_profiler_table);
+ g_mem_profile();
+#endif
+
g_type_init();
g_thread_init(NULL);
gtk_init(&argc, &argv);