Bug 146444 - rocksndiamonds-3.1.1-2: array subscript out of range
Summary: rocksndiamonds-3.1.1-2: array subscript out of range
Status: RESOLVED FIXED
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: unspecified
Hardware: All SUSE Other
: P5 - None : Minor
Target Milestone: ---
Assignee: Michal Marek
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-28 11:14 UTC by David Binderman
Modified: 2006-01-31 17:52 UTC (History)
0 users

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Binderman 2006-01-28 11:14:53 UTC
I just tried to compile package rocksndiamonds-3.1.1-2 with the Intel C compiler.

It said

init.c(4418): warning #175: subscript out of range

The source code is

	music_id_prefix[MAX_LEVELS] = NULL;

but

  static char *music_id_prefix[NUM_MUSIC_PREFIXES + 1];

and

#define MAX_LEVELS                     1000
#define NUM_MUSIC_PREFIXES             1

I agree with the compiler.  Suggest new code

	music_id_prefix[NUM_MUSIC_PREFIXES] = NULL;
Comment 1 Michal Marek 2006-01-31 17:52:57 UTC
Hi,

thanks for finding the bug. I've submitted the fix into our distribution and also
contacted the author (Holger Schemel <info@artsoft.org>).