m68k: Add missing sign extension SDL-1.2
authorPatrice Mandin <patmandin@gmail.com>
Sun, 27 Jul 2014 19:19:47 +0200
branchSDL-1.2
changeset 9013 7f4407040fbd
parent 8918 3c8124d60e8e
child 9018 4a9c67d11c9f
m68k: Add missing sign extension
src/audio/SDL_mixer_m68k.c
--- a/src/audio/SDL_mixer_m68k.c	Tue Jun 24 01:32:20 2014 -0700
+++ b/src/audio/SDL_mixer_m68k.c	Sun Jul 27 19:19:47 2014 +0200
@@ -82,6 +82,7 @@
 "	moveq	#0,%%d1\n"
 
 "	moveb	%1@+,%%d0\n"	/* d0 = *src++ */
+"	extw	%%d0\n"
 "	muls	%3,%%d0\n"	/* d0 *= volume (0<=volume<=128) */
 "	moveb	%0@,%%d1\n"	/* d1 = *dst */
 "	asr	#7,%%d0\n"	/* d0 /= 128 (SDL_MIX_MAXVOLUME) */