Is there a Windows string function that expands escape sequences such as %n, %t, etc, and which is replicated by Wine?
I ask because I have a Windows app that is screwing up because of something like this. It has a private .ini settings file, and some settings are stored in that kind of format, but when it runs on Wine they are wrongly retrieved (this is a 3rd party app, I don't have the source).
It looks horribly like %n is being expanded to NL instead of CR-NL. If there's a Windows/Wine function for this then I might be able to use a native DLL to get round it, but I've no idea where it might reside! AFAIK GetPrivateProfileString() doesn't do this expansion inherently.
Also if it is the case that the behaviour's different, then I would say it's a Wine bug.
Any ideas appreciated.
Rick
2009/3/8 Rick Jones rick@activeservice.co.uk:
Is there a Windows string function that expands escape sequences such as %n, %t, etc, and which is replicated by Wine?
FormatMessageA/W?
I ask because I have a Windows app that is screwing up because of something like this. It has a private .ini settings file, and some settings are stored in that kind of format, but when it runs on Wine they are wrongly retrieved (this is a 3rd party app, I don't have the source).
It looks horribly like %n is being expanded to NL instead of CR-NL. If there's a Windows/Wine function for this then I might be able to use a native DLL to get round it, but I've no idea where it might reside! AFAIK GetPrivateProfileString() doesn't do this expansion inherently.
Also if it is the case that the behaviour's different, then I would say it's a Wine bug.
Any ideas appreciated.
--On Sunday, March 08, 2009 14:12:16 +0000 Rob Shearman robertshearman@gmail.com wrote:
¦ 2009/3/8 Rick Jones rick@activeservice.co.uk: ¦ > Is there a Windows string function that expands escape sequences such as %n, ¦ > %t, etc, and which is replicated by Wine? ¦ ¦ FormatMessageA/W?
Hmm, could be, possibly the only function that fits the bill. If my theory was right, then changing %n in the ini file to %r%n would work - but it doesn't :(
Also, FormatMessage is in kernel32, so not much chance of a native DLL either :-/
Ho-hum, could be time to get onto the developer and see if he's interested in making his app. work under Wine.
Cheers.
¦ > I ask because I have a Windows app that is screwing up because of something ¦ > like this. It has a private .ini settings file, and some settings are stored ¦ > in that kind of format, but when it runs on Wine they are wrongly retrieved ¦ > (this is a 3rd party app, I don't have the source). ¦ > ¦ > It looks horribly like %n is being expanded to NL instead of CR-NL. If ¦ > there's a Windows/Wine function for this then I might be able to use a ¦ > native DLL to get round it, but I've no idea where it might reside! AFAIK ¦ > GetPrivateProfileString() doesn't do this expansion inherently. ¦ > ¦ > Also if it is the case that the behaviour's different, then I would say it's ¦ > a Wine bug. ¦ > ¦ > Any ideas appreciated. ¦ ¦ -- ¦ Rob Shearman ¦