diff options
author | Johannes Schickel | 2011-07-01 05:38:20 +0200 |
---|---|---|
committer | Johannes Schickel | 2011-07-01 05:42:54 +0200 |
commit | 933ee5b156fd8031a75b84bae5329843221208dc (patch) | |
tree | 17c2c8480e338aeae0479608e662a0e3130a34a9 /engines/scumm | |
parent | 685e32dbd7bf352c27e935b930ea24dc8b3380da (diff) | |
download | scummvm-rg350-933ee5b156fd8031a75b84bae5329843221208dc.tar.gz scummvm-rg350-933ee5b156fd8031a75b84bae5329843221208dc.tar.bz2 scummvm-rg350-933ee5b156fd8031a75b84bae5329843221208dc.zip |
GRAPHICS: Remove default values from FontSJIS::drawChar.
drawChar is overloaded in FontSJIS. One takes a "Surface &" as first
parameter another one "void *", they furthermore have the exact same
number of required parameters. The one "void *" just had a few extra
parameters with default values. This resulted in a bug in SCUMM, where
"VirtScreen *" (a subclass of Surface) was passed instead of "VirtScreen &"
and thus the method taking "void *" was incorrectly used.
To make it easier to spot such bugs in the future I just removed the default
values and thus disallow such calls.
Diffstat (limited to 'engines/scumm')
-rw-r--r-- | engines/scumm/charset.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/scumm/charset.cpp b/engines/scumm/charset.cpp index 7fb834ce98..eaae64dc77 100644 --- a/engines/scumm/charset.cpp +++ b/engines/scumm/charset.cpp @@ -779,7 +779,7 @@ void CharsetRendererV3::printChar(int chr, bool ignoreCharsetMask) { drawBits1(*vs, dst, charPtr, drawTop, origWidth, origHeight, vs->format.bytesPerPixel); #ifndef DISABLE_TOWNS_DUAL_LAYER_MODE else if (_vm->_cjkFont) - _vm->_cjkFont->drawChar(vs, chr, _left, drawTop, _color, _shadowColor); + _vm->_cjkFont->drawChar(*vs, chr, _left, drawTop, _color, _shadowColor); #endif } else { dst = (byte *)_vm->_textSurface.getBasePtr(_left * _vm->_textSurfaceMultiplier, _top * _vm->_textSurfaceMultiplier); |