简体   繁体   中英

What could be causes of “ordinal N not found in DLL” error if it's actually exported?

I was dumb enough to get a GFWL -encumbered game (and GFWL is down). I found some project called XLiveLess that aims to re-implement XLive.dll as a stub that does only minimal job that's necessary to run the game.

When I've placed pre-built DLL all I've got is "The ordinal 29 could not be located in the dynamic link library" error. So I've ran a debugger to find the call to that export, deduced the signature, added appropriate code to .cpp and .def files and built the library. Now, after updating the DLL, I'm still getting the same error, but dumpbin /exports xlive.dll clearly shows me that #29 is exported - there's a line 29 000024A0 [NONAME] in the output.

I'm also certain my self-built library is the exact xlive.dll game's accessing - if I remove the binary it starts complaining that DLL's missing. If that matters, I'm currently running this under Windows 8.0 x86_64.

Now I'm lost and confused, and I'm not experienced with Windows programming (did some 15 years ago but forgot almost everything since then). What could be possible causes loader still not finding the exported function, even though it's right there? Am I missing something?

(As for legality of my actions, if those matter, under the jurisdiction I'm living in, I'm explicitly allowed to reverse engineer software for compatibility and interoperability purposes.)

Solved it.

For some reason, completely unknown to me, the ordinal in error message box is off by one for me. So when the error message said "ordinal #29" it meant @30. Which, indeed, was missing, as I've intended to add exports one-by-one and only added @29 (which was missing too, but @30 was checked before it) and wondered why error message didn't change.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM