Debian Bug report logs - #186780
ltris: better memset/memcpy/sizeof patch

version graph

Package: ltris; Maintainer for ltris is Colin Tuckley <colint@debian.org>; Source for ltris is src:ltris.

Reported by: Tom Goulet <tomg@em.ca>

Date: Sat, 29 Mar 2003 21:03:08 UTC

Severity: wishlist

Tags: patch

Found in version 1.0.3-2

Fixed in version ltris/1.0.12-1

Done: Colin Tuckley <colint@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Pascal Hakim <pasc@debian.org>, ltris@packages.qa.debian.org:
Bug#186780; Package ltris. Full text and rfc822 format available.

Acknowledgement sent to Tom Goulet <tomg@em.ca>:
New Bug report received and forwarded. Copy sent to Pascal Hakim <pasc@debian.org>, ltris@packages.qa.debian.org. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Tom Goulet <tomg@em.ca>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: ltris: better memset/memcpy/sizeof patch
Date: Sat, 29 Mar 2003 21:00:15 +0000
Package: ltris
Version: 1.0.3-2
Severity: wishlist
Tags: patch

I went and changed most of the instances of memset and memcpy to use
sizeof([the destination argument]) as the length argument.

As one example, this one in src/tetris.c in function tetris_make_stat
was broken:
    double scores[1024];
[ cut ]
    memset( scores, 0, sizeof( int ) * 1024 );

So I put in this:
    memset( scores, 0, sizeof(scores) );

The patch is at:
http://web.em.ca/~tomg/tmp/ltris-1.0.3.tomg.diff.gz
http://web.em.ca/~tomg/tmp/ltris-1.0.3.tomg.diff.gz.sig

I'm not sure if I know what I'm doing, but I compiled and ran it and it
works.


-- System Information
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux nova 2.4.20 #4 Thu Mar 27 01:30:49 UTC 2003 i586
Locale: LANG=en_GB, LC_CTYPE=en_GB

Versions of packages ltris depends on:
ii  libc6                         2.3.1-14   GNU C Library: Shared libraries an
ii  libsdl-mixer1.2               1.2.4-1.1  mixer library for Simple DirectMed
ii  libsdl1.2debian               1.2.4-1    Simple DirectMedia Layer

-- 
Tom Goulet
 
My contact and cryptography information:
http://web.em.ca/~tomg/contact.html



Reply sent to Colin Tuckley <colint@debian.org>:
You have taken responsibility. (Thu, 29 Oct 2009 07:41:45 GMT) Full text and rfc822 format available.

Notification sent to Tom Goulet <tomg@em.ca>:
Bug acknowledged by developer. (Thu, 29 Oct 2009 07:41:45 GMT) Full text and rfc822 format available.

Message #10 received at 186780-close@bugs.debian.org (full text, mbox):

From: Colin Tuckley <colint@debian.org>
To: 186780-close@bugs.debian.org
Subject: Bug#186780: fixed in ltris 1.0.12-1
Date: Wed, 28 Oct 2009 20:56:58 +0000
Source: ltris
Source-Version: 1.0.12-1

We believe that the bug you reported is fixed in the latest version of
ltris, which is due to be installed in the Debian FTP archive:

ltris_1.0.12-1.diff.gz
  to main/l/ltris/ltris_1.0.12-1.diff.gz
ltris_1.0.12-1.dsc
  to main/l/ltris/ltris_1.0.12-1.dsc
ltris_1.0.12-1_i386.deb
  to main/l/ltris/ltris_1.0.12-1_i386.deb
ltris_1.0.12.orig.tar.gz
  to main/l/ltris/ltris_1.0.12.orig.tar.gz



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 186780@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Colin Tuckley <colint@debian.org> (supplier of updated ltris package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Sat, 24 Oct 2009 15:06:39 +0100
Source: ltris
Binary: ltris
Architecture: source i386
Version: 1.0.12-1
Distribution: unstable
Urgency: low
Maintainer: Colin Tuckley <colint@debian.org>
Changed-By: Colin Tuckley <colint@debian.org>
Description: 
 ltris      - very polished Tetris clone with CPU opponents
Closes: 186780
Changes: 
 ltris (1.0.12-1) unstable; urgency=low
 .
   * New upstream release
   * Use dpatch for changes to upstream
   * Fix errors and usage of "sizeof" (Closes: #186780).
   * Fix English text strings malus => penalty.
Checksums-Sha1: 
 99e028f0e796b45ac52d0ebb50ba2bfeac5543ba 1060 ltris_1.0.12-1.dsc
 bc0b389b520053f97c6415b4d430f55784073c1b 825500 ltris_1.0.12.orig.tar.gz
 ea622afb2a2c03a4ae46f7ad051fe9ed70201d78 8041 ltris_1.0.12-1.diff.gz
 c9d5c4830060405c4cc0f0f4a2450c603934a708 507676 ltris_1.0.12-1_i386.deb
Checksums-Sha256: 
 2554041762ea34fb1686ea8e666413071ed56cce31f7a75117056e8143519359 1060 ltris_1.0.12-1.dsc
 84c1b63ca884d68b57a836b218340d63d0ba56ac7548d8f254657bef5fddef21 825500 ltris_1.0.12.orig.tar.gz
 a5635eed96fa2f0ce40fc8156f372ce8aa6bb2f3668f50aed882d57a484ae0be 8041 ltris_1.0.12-1.diff.gz
 bff2b6c8d13b7c345ba18587e78d92cbbf6604c26fa93fca21578360b7786533 507676 ltris_1.0.12-1_i386.deb
Files: 
 f0b9bf0c4a25ee17cebda37330fceaa3 1060 games optional ltris_1.0.12-1.dsc
 53b00c17a05c438602a52009e65ebde2 825500 games optional ltris_1.0.12.orig.tar.gz
 00c212d3f746c006644c871ca124e813 8041 games optional ltris_1.0.12-1.diff.gz
 5f7a0674d78dd158a4b780b3403606cc 507676 games optional ltris_1.0.12-1_i386.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)

iEYEARECAAYFAkrnZvkACgkQj2OPlhswRc6owQCgwxRhoXaBeWXgj1JMwGuEWqXh
AgsAnjzbfW9QSje4qzVdU5rluPCZOZC2
=6NWf
-----END PGP SIGNATURE-----





Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sun, 06 Dec 2009 07:36:33 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Mon Apr 21 17:06:04 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.