void _gum_symbol_util_init (void) { dbghelp = gum_dbghelp_impl_obtain (); dbghelp->SymInitialize (GetCurrentProcess (), NULL, TRUE); }
static void gum_dbghelp_backtracer_init (GumDbghelpBacktracer * self) { self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self, GUM_TYPE_DBGHELP_BACKTRACER, GumDbghelpBacktracerPrivate); self->priv->dbghelp = gum_dbghelp_impl_obtain (); }
GumBacktracer * gum_backtracer_make_accurate (void) { #if defined (G_OS_WIN32) GumDbgHelpImpl * dbghelp; dbghelp = gum_dbghelp_impl_obtain (); if (dbghelp == NULL) return NULL; return gum_dbghelp_backtracer_new (dbghelp); #elif defined (HAVE_DARWIN) return gum_darwin_backtracer_new (); #elif defined (HAVE_LIBUNWIND) return gum_unw_backtracer_new (); #else return NULL; #endif }