Package: reminiscence
Version: 0.1.9-1
Severity: important
Tags: patch

On an amd64 debian, I can start the application, but each time I select
"start" in the menu, it crashes with the message: "Bad CRC for collision
data".

This bug is known and fixed in Gentoo, see
http://bugs.gentoo.org/show_bug.cgi?id=120787
I took part of their patch (see comment #5 in the above link) and
completed it to avoid a few compilation warnings.

-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (990, 'testing'), (600, 'stable'), (500, 'oldstable'), (300, 
'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.36.3-fg
Locale: LANG=fr_FR.utf8, LC_CTYPE=fr_FR.utf8 (charmap=UTF-8) (ignored: LC_ALL 
set to fr_FR.UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages reminiscence depends on:
ii  libc6                   2.11.2-10        Embedded GNU C Library: Shared lib
ii  libgcc1                 1:4.4.5-10       GCC support library
ii  libsdl1.2debian         1.2.14-6.1       Simple DirectMedia Layer
ii  libstdc++6              4.4.5-10         The GNU Standard C++ Library v3
ii  perl                    5.10.1-17        Larry Wall's Practical Extraction 
ii  zlib1g                  1:1.2.3.4.dfsg-3 compression library - runtime

reminiscence recommends no packages.

reminiscence suggests no packages.

-- no debconf information

-- debsums errors found:
debsums: changed file /usr/games/rs (from reminiscence package)
diff -r e133af627c1c game.cpp
--- a/game.cpp	Tue Feb 15 23:39:22 2011 +0100
+++ b/game.cpp	Wed Feb 16 01:15:23 2011 +0100
@@ -292,7 +292,7 @@ void Game::drawCurrentInventoryItem() {
 void Game::showFinalScore() {
 	playCutscene(0x49);
 	char textBuf[50];
-	sprintf(textBuf, "SCORE %08lu", _score);
+	sprintf(textBuf, "SCORE %08lu", (unsigned long)_score);
 	_vid.drawString(textBuf, (256 - strlen(textBuf) * 8) / 2, 40, 0xE5);
 	strcpy(textBuf, _menu._passwords[7][_skillLevel]);
 	_vid.drawString(textBuf, (256 - strlen(textBuf) * 8) / 2, 16, 0xE7);
@@ -425,7 +425,7 @@ bool Game::handleContinueAbort() {
 		_vid.drawString(str, (256 - strlen(str) * 8) / 2, 104, colors[0]);
 		str = _res.getMenuString(LocaleData::LI_04_ABORT);
 		_vid.drawString(str, (256 - strlen(str) * 8) / 2, 112, colors[1]);
-		sprintf(textBuf, "SCORE  %08lu", _score);
+		sprintf(textBuf, "SCORE  %08lu", (unsigned long)_score);
 		_vid.drawString(textBuf, 64, 154, 0xE3);
 		if (_stub->_pi.dirMask & PlayerInput::DIR_UP) {
 			_stub->_pi.dirMask &= ~PlayerInput::DIR_UP;
@@ -1292,7 +1292,7 @@ void Game::handleInventory() {
 				}
 			} else {
 				char textBuf[50];
-				sprintf(textBuf, "SCORE %08lu", _score);
+				sprintf(textBuf, "SCORE %08lu", (unsigned long)_score);
 				_vid.drawString(textBuf, (114 - strlen(textBuf) * 8) / 2 + 72, 158, 0xE5);
 				sprintf(textBuf, "%s:%s", _res.getMenuString(LocaleData::LI_06_LEVEL), _res.getMenuString(LocaleData::LI_13_EASY + _skillLevel));
 				_vid.drawString(textBuf, (114 - strlen(textBuf) * 8) / 2 + 72, 166, 0xE5);
diff -r e133af627c1c sys.h
--- a/sys.h	Tue Feb 15 23:39:22 2011 +0100
+++ b/sys.h	Wed Feb 16 01:15:23 2011 +0100
@@ -19,12 +19,14 @@
 #ifndef __SYS_H__
 #define __SYS_H__
 
-typedef unsigned char uint8;
-typedef signed char int8;
-typedef unsigned short uint16;
-typedef signed short int16;
-typedef unsigned long uint32;
-typedef signed long int32;
+#include <stdint.h>
+
+typedef uint8_t uint8;
+typedef int8_t int8;
+typedef uint16_t uint16;
+typedef int16_t int16;
+typedef uint32_t uint32;
+typedef int32_t int32;
 
 inline uint16 READ_BE_UINT16(const void *ptr) {
 	const uint8 *b = (const uint8 *)ptr;

Reply via email to