Page 1 of 1

array subscript out of range

Posted: 10.06.2009, 17:22
by Seli
From https://bugzilla.novell.com/show_bug.cgi?id=216330 :
"
I just tried to compile package celestia-1.3.2-38 with the Intel
C compiler.

It said

bigfix.cpp(174): warning #175: subscript out of range

The source code is

if (n[N_WORDS] != 0)

Strange. Not only does n[N_WORDS] not exist, but also it
has no dependency on the loop variable i.

Perhaps the programmer intended

if (n[ i] != 0)
"

"
package celestia-1.5.1-48.3 and the compiler said

bigfix.cpp:168:22: warning: array subscript is above array bounds
"

Re: array subscript out of range

Posted: 10.06.2009, 17:26
by chris
This is fixed in Celestia 1.6.0 (current SVN code base)... The BigFix was rewritten to represent the 128-fixed point values as a pair of 64-bit integers instead of an array of 8 16-bit values.

--Chris