Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
The only difference I can see between the 2 DLLs is the base address, as mentioned before. If you use MS's rebase, and set the base address in broken DLL to 0x62F00000 (base address of the good one) what happens? Have you tried using Dependency Walker on the broken DLL? IDK what pmver is. What is the difference between the 2 DLLs in your experience, compiler flag wise? Since the only different is the base address, it sounds like there is a collision with something that isn't relocatable, or the DLL isn't relocatable for some unknown reason (unknown reloc type entry for example) even though it has reloc info. Also, Dynaloader uses perlhost.h/vdir to possibly change the path, so its not always the path that Dynaloader is reporting exactly. I know you said if you change the file the not a win32 application happens. If you look at http://support.microsoft.com/kb/113996 you will notice many different NTSTATUS codes map to ERROR_BAD_EXE_FORMAT. Using a C debugger to look at the EAX return value of LdrLoadDll in LoadLibraryExW. That will be the native status code. To figure out if relocation failed, set a breakpoint right before "/DynaLoader.pm line 226" (I use system("pause");), run the perl process until the PLPlot load attemp, then use VMMap or MemMapView and look at the address space, and see if there is anything at or near 622c0000 to 0x625D7200 (last section 0x625ce000 + last section length 0x9200 = 0x625D7200 ), then hit space to unfreeze it, and see if it fails with not a valid application.

edit:When boot of PLplot is called, PLPlot's DLL is fully loaded, and the LoadLibrary returned a while ago. "Can't load PDL::Core module" is a croak call in PLplot's boot, so using Dynaloader for broken and ok DLLS, in isolation, is fine. But the PLplot PM file use/load/requires something else, this something else is causing the problem that later causes the bootstrap/LoadLibrary to fail for broken PLplot dll.

In reply to Re^16: if Digest::SHA1 loaded Can't load LibXML/LibXML.dll Invalid access to memory location by bulk88
in thread if Digest::SHA1 loaded Can't load LibXML/LibXML.dll Invalid access to memory location by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (5)
As of 2024-04-23 17:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found