Commit 2ad28d62 authored by Alexandre Julliard's avatar Alexandre Julliard

Don't go through the export table if we are not tracing anything.

parent 6f279109
...@@ -97,20 +97,18 @@ void dump_exports( HMODULE hModule ) ...@@ -97,20 +97,18 @@ void dump_exports( HMODULE hModule )
IMAGE_EXPORT_DIRECTORY *pe_exports = (IMAGE_EXPORT_DIRECTORY*)RVA(rva_start); IMAGE_EXPORT_DIRECTORY *pe_exports = (IMAGE_EXPORT_DIRECTORY*)RVA(rva_start);
Module = (char*)RVA(pe_exports->Name); Module = (char*)RVA(pe_exports->Name);
TRACE("*******EXPORT DATA*******\n"); DPRINTF("*******EXPORT DATA*******\n");
TRACE("Module name is %s, %ld functions, %ld names\n", DPRINTF("Module name is %s, %ld functions, %ld names\n",
Module, pe_exports->NumberOfFunctions, pe_exports->NumberOfNames); Module, pe_exports->NumberOfFunctions, pe_exports->NumberOfNames);
ordinal = RVA(pe_exports->AddressOfNameOrdinals); ordinal = RVA(pe_exports->AddressOfNameOrdinals);
functions = function = RVA(pe_exports->AddressOfFunctions); functions = function = RVA(pe_exports->AddressOfFunctions);
name = RVA(pe_exports->AddressOfNames); name = RVA(pe_exports->AddressOfNames);
TRACE(" Ord RVA Addr Name\n" ); DPRINTF(" Ord RVA Addr Name\n" );
for (i=0;i<pe_exports->NumberOfFunctions;i++, function++) for (i=0;i<pe_exports->NumberOfFunctions;i++, function++)
{ {
if (!*function) continue; /* No such function */ if (!*function) continue; /* No such function */
if (TRACE_ON(win32))
{
DPRINTF( "%4ld %08lx %p", i + pe_exports->Base, *function, RVA(*function) ); DPRINTF( "%4ld %08lx %p", i + pe_exports->Base, *function, RVA(*function) );
/* Check if we have a name for it */ /* Check if we have a name for it */
for (j = 0; j < pe_exports->NumberOfNames; j++) for (j = 0; j < pe_exports->NumberOfNames; j++)
...@@ -123,7 +121,6 @@ void dump_exports( HMODULE hModule ) ...@@ -123,7 +121,6 @@ void dump_exports( HMODULE hModule )
DPRINTF(" (forwarded -> %s)", (char *)RVA(*function)); DPRINTF(" (forwarded -> %s)", (char *)RVA(*function));
DPRINTF("\n"); DPRINTF("\n");
} }
}
} }
/* Look up the specified function or ordinal in the export list: /* Look up the specified function or ordinal in the export list:
...@@ -642,7 +639,7 @@ WINE_MODREF *PE_CreateModule( HMODULE hModule, LPCSTR filename, DWORD flags, ...@@ -642,7 +639,7 @@ WINE_MODREF *PE_CreateModule( HMODULE hModule, LPCSTR filename, DWORD flags,
/* Dump Exports */ /* Dump Exports */
if ( pe_export ) if (pe_export && TRACE_ON(win32))
dump_exports( hModule ); dump_exports( hModule );
/* Fixup Imports */ /* Fixup Imports */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment