http://bugs.winehq.org/show_bug.cgi?id=18823
--- Comment #1 from Torbjörn Söderstedt torbjrn@users.sourceforge.net 2009-08-02 06:18:51 --- Created an attachment (id=22777) --> (http://bugs.winehq.org/attachment.cgi?id=22777) Fix
DSOUND_PrimarySetFormat will copy the new format before checking if it is supported. If changing format fails without causing DSERR_BUFFERLOST, the buffer will have incorrect settings. I created a temporary buffer that is used by the affected code.
The Typing of the Dead tries to set a format with nBlockAlign=0 (wBitsPerSample=2), leading to a division by zero in DSOUND_MixInBuffer.