http://bugs.winehq.org/show_bug.cgi?id=7698
--- Comment #102 from Christian Sonne cers@geeksbynature.dk 2007-08-31 12:45:59 --- (In reply to comment #101)
Yes, this is a font bug.
The source engine uses fonts to render the names and weapon symbols. It creates a d3d surface for them and uses GetGlyphOutline to read the font symbol into that surface.
Unfortunately the surface has a fixed size, and if GetGlyphOutline returns a bigger glyph than hl2 expects, it causes an overflow on the stack and the return address or a class instance pointer that is safed on the stack gets overwritten, and the game crashes a few instructions later.
This is essentially a hl2 bug, because it should honor the size returned by ggo, rather than finding it's own or hardcoding it. Beyond that, I am not sure if Wine or freetype is to be blamed for rendering the font differently, but if it is freetype, then we have a problem. Freetype doesn't aim for bug-for-bug compatiblity with windows as far as I know.
But assuming I only ever intend to use wine for CS:S (probably not the case, but just for arguments sake) would this bug be fixable via applying the same hard-coded limit into the appropriate location in freetype.c ? - and where would that be? :-)