Patch 1/2 for SmartForms Installer: PROFILE_GetString incorrect return value

Andreas Mohr andi at rhlx01.fht-esslingen.de
Sat Jun 22 03:57:31 CDT 2002


On Sat, Jun 22, 2002 at 12:18:07AM -0400, Joshua Thielen wrote:
> This patch fixes an error encountered in the Smart Forms installer 
> (somewhat related to bug 575).
> 
> When calling GetPrivateProfileString with the second parameter as NULL, 
> all of the keys under the specified section are copied to the buffer. 
> The return value should be the number of characters copied minus the 
> last null terminator. Since the keys are copied as null-terminated 
> strings with the last string terminated with two null characters, strlen 
> cannot be used to determine the number of characters copied. This patch 
> corrects PROFILE_GetString for this case.
Hmm, hmm. Could this happen to fix bug #724 also ?
Word97 etc. broke when I handled the "default" case in PROFILE_GetString().
As the log files received didn't show relay lines, only profile lines,
I haven't been able to fix it.
But this sounds like a reasonable cause for it...

-- 
Andreas Mohr                        Stauferstr. 6, D-71272 Renningen, Germany
Tel. +49 7159 800604                http://mohr.de.tt



More information about the wine-devel mailing list