Behaviour of GetModuleFileName

Alexandre Julliard julliard at
Tue May 21 14:34:41 CDT 2002

Warren_Baird at writes:

>   1.  Would anyone object if I tried to fix wine to behave properly with
> GetModuleFileName returning the full path?  I haven't dug into it yet, so I
> don't know how much effort will be required...  Is there a reasons we have the
> current behaviour?

Builtin dlls don't have a full path because there is no associated
file that we could point to (at least as seen from Windows). If this
breaks your app it can be changed, but I'm not sure it will really fix
anything. What does the app do with the filename?

>   2.  I've attached the patch I'm using at the bottom of this message - can
> anyone think of a cleaner way of doing this?

You should not need to change the spec file at all. If you need a full
name you should prefix the name with the windows system directory at
load time.

Alexandre Julliard
julliard at

More information about the wine-devel mailing list