Skip to content

Commit

Permalink
Fix initialization order regression
Browse files Browse the repository at this point in the history
  • Loading branch information
oleavr committed Jan 22, 2016
1 parent fdce440 commit 361b3a0
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions gum/gum.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ static gpointer gum_capstone_calloc (gsize count, gsize size);
static gpointer gum_capstone_realloc (gpointer mem, gsize size);
static void gum_capstone_free (gpointer mem);

static guint page_size;
static GSList * gum_destructors = NULL;

void
Expand Down Expand Up @@ -62,8 +61,6 @@ do_init (gpointer data)
gum_vsnprintf
};

page_size = gum_query_page_size ();

gum_memory_init ();

#if GLIB_CHECK_VERSION (2, 46, 0)
Expand Down Expand Up @@ -135,6 +132,10 @@ gum_capstone_deinit (void)
static gpointer
gum_capstone_malloc (gsize size)
{
guint page_size;

page_size = gum_query_page_size ();

do
{
GumPool * head, * pool;
Expand Down

0 comments on commit 361b3a0

Please sign in to comment.