Commit [r6412]  Maximize  Restore  History

Fix Bug #626; Commander/Editor fonts now persist across restarts for font names between 14 characters and 31 characters.

The bug was due to a character/byte buffer length mixup in GetConfigurationString.
This was likely introduced in FMSLogo 8.0.0, when support for Unicode was added.

I have fixed GetConfigurationString to enable the scenario reported by a user, which is that a commander font name of about 16 characters appeared not to be persisted under wine. However, this fix doesn't work if the font family name is 32 (LF_FACESIZE) characters because GetConfigurationString is designed to always NUL-terminate the value it reads from the registry. I don't know if there are any fonts of 32 characters on Linux.

I didn't see a way to automate a regression test for this bug using the existing Logo test framework, so this revision contains a simple native test framework.

david_costanzo 2026-11-16

changed /logo/trunk/src
changed /logo/trunk/src/CHANGELOG.TXT
changed /logo/trunk/src/Makefile
added /logo/trunk/src/test/unittest.cpp
changed /logo/trunk/src/utils.cpp
/logo/trunk/src
Directory.
/logo/trunk/src/CHANGELOG.TXT Diff Switch to side-by-side view
Loading...
/logo/trunk/src/Makefile Diff Switch to side-by-side view
Loading...
/logo/trunk/src/test/unittest.cpp Diff Switch to side-by-side view
Loading...
/logo/trunk/src/utils.cpp Diff Switch to side-by-side view
Loading...