--with-gc enables now support for Boehm's GC, if it's found and glib2 is

used. This also enables an extra check for perl library to verify scripts
aren't using objects that have already been free'd - while not a fully safe
solution it's much better than before :)


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3063 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2002-12-23 06:06:14 +00:00 committed by cras
commit cdc52b773e
3 changed files with 117 additions and 4 deletions

View file

@ -309,6 +309,17 @@ static void winsock_init(void)
}
#endif
#ifdef HAVE_GC
#include <gc/gc.h>
GMemVTable gc_mem_table = {
GC_malloc,
GC_realloc,
GC_free,
NULL, NULL, NULL
};
#endif
int main(int argc, char **argv)
{
static struct poptOption options[] = {
@ -316,6 +327,10 @@ int main(int argc, char **argv)
{ NULL, '\0', 0, NULL }
};
#ifdef HAVE_GC
g_mem_set_vtable(&gc_mem_table);
#endif
dummy = FALSE;
quitting = FALSE;
core_init_paths(argc, argv);